aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files/js/filesummary.js
diff options
context:
space:
mode:
Diffstat (limited to 'apps/files/js/filesummary.js')
-rw-r--r--apps/files/js/filesummary.js10
1 files changed, 6 insertions, 4 deletions
diff --git a/apps/files/js/filesummary.js b/apps/files/js/filesummary.js
index 54d038d86c6..00f13249ff3 100644
--- a/apps/files/js/filesummary.js
+++ b/apps/files/js/filesummary.js
@@ -36,10 +36,12 @@
this.$el = $tr;
var filesConfig = options.config;
if (filesConfig) {
- this._showHidden = !!filesConfig.get('showhidden');
- filesConfig.on('change:showhidden', function() {
- self._showHidden = !!this.get('showhidden');
- self.update();
+ this._showHidden = !!filesConfig.show_hidden;
+ window._nc_event_bus.subscribe('files:config:updated', ({ key, value }) => {
+ if (key === 'show_hidden') {
+ self._showHidden = !!value;
+ self.update();
+ }
});
}
this.clear();