diff --git a/app/init.php b/app/init.php index b0dec5322..7bf97d9d9 100644 --- a/app/init.php +++ b/app/init.php @@ -32,7 +32,7 @@ const APP_EMAIL_SECURITY = 'security@localhost.test'; // Default security email const APP_USERAGENT = APP_NAME.'-Server v%s. Please report abuse at %s'; const APP_MODE_ADMIN = 'admin'; const APP_PAGING_LIMIT = 15; -const APP_CACHE_BUSTER = 69; +const APP_CACHE_BUSTER = 87; const APP_VERSION_STABLE = '0.5.3'; const APP_STORAGE_UPLOADS = '/storage/uploads'; const APP_STORAGE_CACHE = '/storage/cache'; diff --git a/public/scripts/views/ui/open.js b/public/scripts/views/ui/open.js index af56ff034..714856bde 100644 --- a/public/scripts/views/ui/open.js +++ b/public/scripts/views/ui/open.js @@ -101,14 +101,20 @@ }); } - element.addEventListener("click", function(event) { - let target = findParent("a", event.target); + element.addEventListener('click', function(event) { + let targetA = findParent('a', event.target); + let targetB = findParent('button', event.target); - if (!target) { + if (!targetA && !targetB) { return false; // no target } + + if (targetA && !targetA.href) { + // Just a normal click not an href + return false; + } - if (!target.href) { + if (targetB && !targetB.classList.contains('link')) { // Just a normal click not an href return false; }