1
0
mirror of https://github.com/lus/pasty.git synced 2023-08-10 21:13:09 +03:00

Implement deletion token toggle & master

This commit is contained in:
Lukas Schulte Pelkum
2021-04-20 16:38:00 +02:00
parent f9fc232afe
commit 542bb5b17d
7 changed files with 72 additions and 36 deletions

View File

@@ -63,7 +63,9 @@ export function setupButtons() {
const data = await response.json();
// Give the user the chance to copy the deletion token
prompt("The deletion token for your paste is:", data.deletionToken);
if (data.deletionToken) {
prompt("The deletion token for your paste is:", data.deletionToken);
}
// Redirect the user to the paste page
let address = location.protocol + "//" + location.host + "/" + data.id;