Merge pull request #3330 from tomers/reverse-in-a-single-line

Reverse in a single line
This commit is contained in:
Sergey G. Brester 2022-08-09 17:23:18 +02:00 committed by GitHub
commit 92d5455bdd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -305,9 +305,7 @@ class Actions(JailThread, Mapping):
"""
if actions is None:
actions = self._actions
revactions = actions.items()
revactions.reverse()
for name, action in revactions:
for name, action in reversed(actions.items()):
try:
action.stop()
except Exception as e: