#3 Decorators missing

open
nobody
None
5
2010-01-17
2010-01-17
Anonymous
No

I have a decorator for making classes as singleton pattern:
def singleton(cls):
instances = {}
def getinstance():
if cls not in instances:
instances[cls] = cls()
return instances[cls]
return getinstance

but during synchronization ,app throws the exception .

Discussion