mirror of
https://github.com/vincentbernat/i3wm-configuration.git
synced 2025-06-30 21:34:21 +02:00
i3-companion: simplify static decorator
This commit is contained in:
parent
38f4f5b1a4
commit
66f8fcbef7
1 changed files with 1 additions and 2 deletions
|
@ -130,8 +130,7 @@ def static(**kwargs):
|
|||
"""Define static variables for the event handler."""
|
||||
|
||||
def decorator(fn):
|
||||
for k, v in kwargs.items():
|
||||
setattr(fn, k, v)
|
||||
fn.__dict__.update(kwargs)
|
||||
return fn
|
||||
|
||||
return decorator
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue