diff --git a/app/scripts/background.js b/app/scripts/background.js index 9dc28d238..5eac5d1d6 100644 --- a/app/scripts/background.js +++ b/app/scripts/background.js @@ -801,6 +801,13 @@ export function setupController( }); } ///: END:ONLY_INCLUDE_IN + + ///: BEGIN:ONLY_INCLUDE_IN(snaps) + // Updates the snaps registry and check for newly blocked snaps to block if the user has at least one snap installed. + if (Object.keys(controller.snapController.state.snaps).length > 0) { + controller.snapController.updateBlockedSnaps(); + } + ///: END:ONLY_INCLUDE_IN } // diff --git a/app/scripts/metamask-controller.js b/app/scripts/metamask-controller.js index 04f2ce22e..f0e87fd6c 100644 --- a/app/scripts/metamask-controller.js +++ b/app/scripts/metamask-controller.js @@ -986,6 +986,7 @@ export default class MetamaskController extends EventEmitter { 'ExecutionService:handleRpcRequest', 'SnapsRegistry:get', 'SnapsRegistry:getMetadata', + 'SnapsRegistry:update', ], });