mirror of
https://gitlab.com/timvisee/send.git
synced 2025-12-08 23:18:39 +03:00
if checkexistence removes the last item in the list, call toggleHeader
This commit is contained in:
@@ -80,6 +80,7 @@ $(document).ready(function() {
|
|||||||
$copyBtn.attr('data-l10n-id', 'copyUrlFormButton');
|
$copyBtn.attr('data-l10n-id', 'copyUrlFormButton');
|
||||||
|
|
||||||
const files = storage.files;
|
const files = storage.files;
|
||||||
|
console.log(files);
|
||||||
if (files.length === 0) {
|
if (files.length === 0) {
|
||||||
toggleHeader();
|
toggleHeader();
|
||||||
} else {
|
} else {
|
||||||
@@ -90,6 +91,7 @@ $(document).ready(function() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// copy link to clipboard
|
// copy link to clipboard
|
||||||
$copyBtn.click(() => {
|
$copyBtn.click(() => {
|
||||||
// record copied event from success screen
|
// record copied event from success screen
|
||||||
@@ -341,6 +343,9 @@ $(document).ready(function() {
|
|||||||
}
|
}
|
||||||
} else if (xhr.status === 404) {
|
} else if (xhr.status === 404) {
|
||||||
storage.remove(id);
|
storage.remove(id);
|
||||||
|
if (storage.numFiles === 0) {
|
||||||
|
toggleHeader();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user