mirror of
https://github.com/jwinterm/modoboa.git
synced 2026-11-12 08:53:56 +01:00
Webmail improvements. (drap&drop of messages for moving and deleting, empty trash, etc.)
This commit is contained in:
@@ -78,3 +78,14 @@ def getoption(name, default=None):
|
||||
except AttributeError:
|
||||
res = default
|
||||
return res
|
||||
|
||||
|
||||
class Singleton(type):
|
||||
def __init__(cls, name, bases, dict):
|
||||
super(Singleton, cls).__init__(name, bases, dict)
|
||||
cls.instance = None
|
||||
|
||||
def __call__(cls, *args, **kwargs):
|
||||
if cls.instance is None:
|
||||
cls.instance = super(Singleton, cls).__call__(*args, **kwargs)
|
||||
return cls.instance
|
||||
|
||||
Reference in New Issue
Block a user