aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/components/services/content/ServiceWebview.js4
-rw-r--r--src/features/workspaces/store.js12
2 files changed, 3 insertions, 13 deletions
diff --git a/src/components/services/content/ServiceWebview.js b/src/components/services/content/ServiceWebview.js
index 4bab4a964..b3198d36a 100644
--- a/src/components/services/content/ServiceWebview.js
+++ b/src/components/services/content/ServiceWebview.js
@@ -37,9 +37,7 @@ class ServiceWebview extends Component {
37 <ElectronWebView 37 <ElectronWebView
38 ref={(webview) => { 38 ref={(webview) => {
39 this.webview = webview; 39 this.webview = webview;
40 if (webview && webview.view) { 40 webview.view.addEventListener('did-stop-loading', this.refocusWebview);
41 webview.view.addEventListener('did-stop-loading', this.refocusWebview);
42 }
43 }} 41 }}
44 autosize 42 autosize
45 src={service.url} 43 src={service.url}
diff --git a/src/features/workspaces/store.js b/src/features/workspaces/store.js
index f08323e6c..7f41cfc88 100644
--- a/src/features/workspaces/store.js
+++ b/src/features/workspaces/store.js
@@ -141,16 +141,8 @@ export default class WorkspacesStore extends FeatureStore {
141 141
142 filterServicesByActiveWorkspace = (services) => { 142 filterServicesByActiveWorkspace = (services) => {
143 const { activeWorkspace, isFeatureActive } = this; 143 const { activeWorkspace, isFeatureActive } = this;
144 if (isFeatureActive) { 144 if (isFeatureActive && activeWorkspace) {
145 if (activeWorkspace) { 145 return this.getWorkspaceServices(activeWorkspace);
146 return this.getWorkspaceServices(activeWorkspace);
147 }
148 // There is no active workspace yet but we might be still loading them
149 if (!getUserWorkspacesRequest.wasExecuted || getUserWorkspacesRequest.isExecutingFirstTime) {
150 // If so, do not show any services to avoid loading all of them unfiltered
151 // and then having the filter flashing in (which is ugly and slow).
152 return [];
153 }
154 } 146 }
155 return services; 147 return services;
156 }; 148 };