forked from Maurice/pastabble
Fix
This commit is contained in:
parent
f5aac579ff
commit
049a1b0125
@ -45,7 +45,10 @@
|
||||
});
|
||||
|
||||
if(res.ok) {
|
||||
const id = await res.text();
|
||||
let id = await res.text();
|
||||
if(id.includes('/')) {
|
||||
id = id.substring(id.lastIndexOf('/') + 1);
|
||||
}
|
||||
push(`/${id}`);
|
||||
}
|
||||
}
|
||||
@ -75,7 +78,10 @@
|
||||
});
|
||||
|
||||
if(res.status === 200) {
|
||||
const id = await res.text();
|
||||
let id = await res.text();
|
||||
if(id.includes('/')) {
|
||||
id = id.substring(id.lastIndexOf('/') + 1);
|
||||
}
|
||||
createdUrl = `${location.origin}/to/${id}`;
|
||||
enteredUrl = '';
|
||||
showAlert = true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user