From 745027bf93ba4d8fbee27b3fd18b7853c0eff803 Mon Sep 17 00:00:00 2001 From: Mike Salvatore Date: Mon, 12 Sep 2022 13:46:45 -0400 Subject: [PATCH] Island: Wrap island event handler setup in separate function --- monkey/monkey_island/cc/setup/island_event_handlers.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/monkey/monkey_island/cc/setup/island_event_handlers.py b/monkey/monkey_island/cc/setup/island_event_handlers.py index 9df1df752..9f179f315 100644 --- a/monkey/monkey_island/cc/setup/island_event_handlers.py +++ b/monkey/monkey_island/cc/setup/island_event_handlers.py @@ -6,6 +6,12 @@ from monkey_island.cc.island_event_handlers import reset_agent_configuration def setup_island_event_handlers(container: DIContainer): event_queue = container.resolve(IIslandEventQueue) + _handle_reset_agent_configuration_events(event_queue, container) + + +def _handle_reset_agent_configuration_events( + event_queue: IIslandEventQueue, container: DIContainer +): event_queue.subscribe( IslandEventTopic.RESET_AGENT_CONFIGURATION, container.resolve(reset_agent_configuration) )