Merge pull request #11709 from nextcloud/refactor/jquery-beforeunload

Fix depracted jQuery.bind call
This commit is contained in:
Morris Jobke 2018-10-09 14:48:42 +02:00 committed by GitHub
commit 877823eb9d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -3432,7 +3432,7 @@
$(document).ready(function() {
// FIXME: unused ?
OCA.Files.FileList.useUndo = (window.onbeforeunload)?true:false;
$(window).bind('beforeunload', function () {
$(window).on('beforeunload', function () {
if (OCA.Files.FileList.lastAction) {
OCA.Files.FileList.lastAction();
}