diff options
author | Christoph Wurst <christoph@winzerhof-wurst.at> | 2016-10-10 17:35:11 +0200 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2016-11-07 14:58:45 +0100 |
commit | c55718ae5e6eb3ebde519e3a4954e8b339734067 (patch) | |
tree | 641fc693d2dcc620d772cc87d6cdc375fee3b927 /apps/files | |
parent | 36cf77914069cd63b4d70d2ca0658f9000cddf78 (diff) | |
download | nextcloud-server-c55718ae5e6eb3ebde519e3a4954e8b339734067.tar.gz nextcloud-server-c55718ae5e6eb3ebde519e3a4954e8b339734067.zip |
update breadcrumb view whenever the share information on the directory info model changes
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
Diffstat (limited to 'apps/files')
-rw-r--r-- | apps/files/js/filelist.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/apps/files/js/filelist.js b/apps/files/js/filelist.js index 5bdb1a8999d..c53fa4f3d66 100644 --- a/apps/files/js/filelist.js +++ b/apps/files/js/filelist.js @@ -473,7 +473,7 @@ * Displays the details view for the given file and * selects the given tab * - * @param {string} fileName file name for which to show details + * @param {string|OCA.Files.FileInfoModel} fileName file name or FileInfoModel for which to show details * @param {string} [tabId] optional tab id to select */ showDetailsView: function(fileName, tabId) { @@ -487,7 +487,7 @@ /** * Update the details view to display the given file * - * @param {string} fileName file name from the current list + * @param {string|OCA.Files.FileInfoModel} fileName file name from the current list or a FileInfoModel object * @param {boolean} [show=true] whether to open the sidebar if it was closed */ _updateDetailsView: function(fileName, show) { @@ -518,8 +518,8 @@ OC.Apps.showAppSidebar(this._detailsView.$el); } - if (_.isObject(fileName)) { - var model = new OCA.Files.FileInfoModel(fileName); + if (fileName instanceof OCA.Files.FileInfoModel) { + var model = fileName; } else { var $tr = this.findFileEl(fileName); var model = this.getModelForFile($tr); @@ -2025,7 +2025,7 @@ function updateInList(fileInfo) { self.updateRow(tr, fileInfo); - self._updateDetailsView(fileInfo.name, false); + self._updateDetailsView(fileInfo, false); } // TODO: too many nested blocks, move parts into functions |