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