diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/features/workspaces/store.js | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/features/workspaces/store.js b/src/features/workspaces/store.js index 51a7f3651..6118df79a 100644 --- a/src/features/workspaces/store.js +++ b/src/features/workspaces/store.js | |||
@@ -312,17 +312,13 @@ export default class WorkspacesStore extends FeatureStore { | |||
312 | 312 | ||
313 | _cleanupInvalidServiceReferences = () => { | 313 | _cleanupInvalidServiceReferences = () => { |
314 | const { services } = this.stores; | 314 | const { services } = this.stores; |
315 | let invalidServiceReferencesExist = false; | ||
316 | this.workspaces.forEach((workspace) => { | 315 | this.workspaces.forEach((workspace) => { |
317 | workspace.services.forEach((serviceId) => { | 316 | workspace.services.forEach((serviceId) => { |
318 | if (!services.one(serviceId)) { | 317 | if (services.allServicesRequest.wasExecuted && !services.one(serviceId)) { |
319 | invalidServiceReferencesExist = true; | 318 | workspace.services.remove(serviceId); |
320 | } | 319 | } |
321 | }); | 320 | }); |
322 | }); | 321 | }); |
323 | if (invalidServiceReferencesExist) { | ||
324 | getUserWorkspacesRequest.execute(); | ||
325 | } | ||
326 | }; | 322 | }; |
327 | 323 | ||
328 | _stopPremiumActionsAndReactions = () => { | 324 | _stopPremiumActionsAndReactions = () => { |