pyln: Fix up the mypy annotation for init self-disabling

This commit is contained in:
Christian Decker 2021-07-26 12:17:23 +02:00 committed by Rusty Russell
parent f5e08c3dae
commit 0da87e7715

View file

@ -274,7 +274,11 @@ class Plugin(object):
self.rpc: Optional[LightningRpc] = None
self.startup = True
self.dynamic = dynamic
self.child_init: Optional[Callable[..., None]] = None
# The function registering as init may return a dict of the
# form `{'disable': 'why'}` to self-disable, however most
# commonly you'll want to return `None`
self.child_init: Optional[Callable[..., Optional[dict]]] = None
self.write_lock = RLock()