Created
November 28, 2018 17:05
-
-
Save mkrizek/c9a980023ab8e9e10a36ba5bbbad05a0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/ansible/plugins/strategy/__init__.py b/lib/ansible/plugins/strategy/__init__.py | |
index 41b74edabd..98466cb37c 100644 | |
--- a/lib/ansible/plugins/strategy/__init__.py | |
+++ b/lib/ansible/plugins/strategy/__init__.py | |
@@ -368,7 +368,7 @@ class StrategyBase: | |
return self._inventory.get_host(host_name) | |
def search_handler_blocks_by_name(handler_name, handler_blocks): | |
- for handler_block in handler_blocks: | |
+ for handler_block in reversed(handler_blocks): | |
for handler_task in handler_block.block: | |
if handler_task.name: | |
handler_vars = self._variable_manager.get_vars(play=iterator._play, task=handler_task) | |
@@ -394,7 +394,7 @@ class StrategyBase: | |
return None | |
def search_handler_blocks_by_uuid(handler_uuid, handler_blocks): | |
- for handler_block in handler_blocks: | |
+ for handler_block in reversed(handler_blocks): | |
for handler_task in handler_block.block: | |
if handler_uuid == handler_task._uuid: | |
return handler_task |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment