summaryrefslogtreecommitdiff
path: root/poezio/singleton.py
diff options
context:
space:
mode:
Diffstat (limited to 'poezio/singleton.py')
-rw-r--r--poezio/singleton.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/poezio/singleton.py b/poezio/singleton.py
index 9133012b..7f12796b 100644
--- a/poezio/singleton.py
+++ b/poezio/singleton.py
@@ -13,8 +13,8 @@ This method is the only one that I can come up with that do not call
__init__() each time.
"""
-instances = {}
+_instances = {}
def Singleton(cls, *args, **kwargs):
- if not cls in instances:
- instances[cls] = cls(*args, **kwargs)
- return instances[cls]
+ if not cls in _instances:
+ _instances[cls] = cls(*args, **kwargs)
+ return _instances[cls]