Update copyright dates for files changed this year
[mudpy.git] / mudpy / daemon.py
index 2413204..952831f 100644 (file)
@@ -1,13 +1,18 @@
-# Copyright (c) 2004-2016 Jeremy Stanley <fungi@yuggoth.org>. Permission
+# Copyright (c) 2004-2017 Jeremy Stanley <fungi@yuggoth.org>. Permission
 # to use, copy, modify, and distribute this software is granted under
 # terms provided in the LICENSE file distributed with this software.
 
 # core objects for the mudpy engine
-import imp
 import sys
 
 import mudpy
 
+if sys.version_info >= (3, 4):
+    import importlib
+else:
+    # Python 3.3 lacks importlib.reload()
+    import imp as importlib
+
 
 def main():
 
@@ -21,7 +26,7 @@ def main():
 
         # the world was flagged for a reload of all code/data
         if mudpy.misc.universe.reload_flag:
-            imp.reload(mudpy)
+            importlib.reload(mudpy)
             mudpy.misc.reload_data()
             mudpy.misc.universe.reload_flag = False