From af220c7f7b3b1a33546a82ef1285be1caf2df1a8 Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Mon, 21 Mar 2016 15:02:09 -0700 Subject: [PATCH] ItemViewContainer didn't exist sometimes for root folders Fixed: Error displaying existing root folders in some cases Closes #1170 --- src/UI/AddSeries/RootFolders/RootFolderLayout.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/UI/AddSeries/RootFolders/RootFolderLayout.js b/src/UI/AddSeries/RootFolders/RootFolderLayout.js index 0b3238ee8..6dae383d7 100644 --- a/src/UI/AddSeries/RootFolders/RootFolderLayout.js +++ b/src/UI/AddSeries/RootFolders/RootFolderLayout.js @@ -27,10 +27,10 @@ var Layout = Marionette.Layout.extend({ this.rootfolderListView = new RootFolderCollectionView({ collection : RootFolderCollection }); this.listenTo(this.rootfolderListView, 'itemview:folderSelected', this._onFolderSelected); - this.listenTo(RootFolderCollection, 'sync', this._showCurrentDirs); }, - onRender : function() { + onShow : function() { + this.listenTo(RootFolderCollection, 'sync', this._showCurrentDirs); this.currentDirs.show(new LoadingView()); if (RootFolderCollection.synced) {