From c9476115b0504fc132169b4fa4ef55d6f97a40ab Mon Sep 17 00:00:00 2001 From: Vincent Petry Date: Wed, 2 Mar 2016 17:42:51 +0100 Subject: [PATCH] Return false on 401 in file list + trash file list This gives a chance to the global ajax error handler to do its work if the session expired. --- apps/files/js/filelist.js | 4 ++++ apps/files_trashbin/js/filelist.js | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/apps/files/js/filelist.js b/apps/files/js/filelist.js index 95fdac02c2..fcdf6caaa5 100644 --- a/apps/files/js/filelist.js +++ b/apps/files/js/filelist.js @@ -1436,6 +1436,10 @@ delete this._reloadCall; this.hideMask(); + if (status === 401) { + return false; + } + // Firewall Blocked request? if (status === 403) { // Go home diff --git a/apps/files_trashbin/js/filelist.js b/apps/files_trashbin/js/filelist.js index 5812aff82f..feed28d8fc 100644 --- a/apps/files_trashbin/js/filelist.js +++ b/apps/files_trashbin/js/filelist.js @@ -325,6 +325,10 @@ return false; } + if (result.status === 401) { + return false; + } + // Firewall Blocked request? if (result.status === 403) { // Go home