summaryrefslogtreecommitdiff
path: root/dotbot/messenger
diff options
context:
space:
mode:
authorAnish Athalye <me@anishathalye.com>2015-01-26 10:36:36 -0500
committerAnish Athalye <me@anishathalye.com>2015-01-26 10:36:36 -0500
commit69502854aaa7597bca9b341b3ce05efa10b4b9d1 (patch)
treef814ae3393c26201ba82e9eb8b48e371e6cba0e1 /dotbot/messenger
parentc638e25941d3ce927efa6672f474f3e0c6bf03a7 (diff)
Fix compatibility
This commit fixes usage of the Singleton metaclass so that it is compatible with both Python 2 and Python 3.
Diffstat (limited to 'dotbot/messenger')
-rw-r--r--dotbot/messenger/messenger.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/dotbot/messenger/messenger.py b/dotbot/messenger/messenger.py
index 9a85a48..f87a367 100644
--- a/dotbot/messenger/messenger.py
+++ b/dotbot/messenger/messenger.py
@@ -1,11 +1,10 @@
import sys
from ..util.singleton import Singleton
+from ..util.compat import with_metaclass
from .color import Color
from .level import Level
-class Messenger(object):
- __metaclass__ = Singleton
-
+class Messenger(with_metaclass(Singleton, object)):
def __init__(self, level = Level.LOWINFO):
self.set_level(level)