From e99b8a8de71dc72627813c3c12dcde1c8f0facba Mon Sep 17 00:00:00 2001 From: David Wilson Date: Mon, 21 Jan 2019 19:38:52 +0000 Subject: [PATCH] core: replace ancient YOLO loop in fire(). --- mitogen/core.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mitogen/core.py b/mitogen/core.py index 893a1e1e..7aea8704 100644 --- a/mitogen/core.py +++ b/mitogen/core.py @@ -329,7 +329,8 @@ def fire(obj, name, *args, **kwargs): registered for the named signal on `obj`. """ signals = vars(obj).get('_signals', {}) - return [func(*args, **kwargs) for func in signals.get(name, ())] + for func in signals.get(name, ()): + func(*args, **kwargs) def takes_econtext(func):