summaryrefslogtreecommitdiffstats
path: root/deluge/core/alertmanager.py
diff options
context:
space:
mode:
Diffstat (limited to 'deluge/core/alertmanager.py')
-rw-r--r--deluge/core/alertmanager.py12
1 files changed, 1 insertions, 11 deletions
diff --git a/deluge/core/alertmanager.py b/deluge/core/alertmanager.py
index 2fe42224d..9d5c18ccb 100644
--- a/deluge/core/alertmanager.py
+++ b/deluge/core/alertmanager.py
@@ -15,10 +15,8 @@ This should typically only be used by the Core. Plugins should utilize the
`:mod:EventManager` for similar functionality.
"""
-from __future__ import unicode_literals
-
import logging
-import types
+from types import SimpleNamespace
from twisted.internet import reactor
@@ -28,14 +26,6 @@ from deluge.common import decode_bytes
log = logging.getLogger(__name__)
-try:
- SimpleNamespace = types.SimpleNamespace # Python 3.3+
-except AttributeError:
-
- class SimpleNamespace(object): # Python 2.7
- def __init__(self, **attr):
- self.__dict__.update(attr)
-
class AlertManager(component.Component):
"""AlertManager fetches and processes libtorrent alerts"""