Browse Source

fixed the datetime referencing.

Signed-off-by: Nicholas Tan Jerome <nicholas.jerome@kit.edu>
Nicholas Tan Jerome 6 years ago
parent
commit
6f42327669
1 changed files with 1 additions and 1 deletions
  1. 1 1
      core.py

+ 1 - 1
core.py

@@ -195,7 +195,7 @@ class VersionHandler(tornado.web.RequestHandler):
 class BackupHandler(tornado.web.RequestHandler):
     def post(self):
         backup_dst = os.getcwd() + "/backup/"
-        fname = datetime.now().strftime("%Y-%m-%d_%H-%M-%S")
+        fname = datetime.datetime.now().strftime("%Y-%m-%d_%H-%M-%S")
         os.makedirs(backup_dst + fname)
         copyfile("varname.yaml", backup_dst +
                  fname + "/varname.yaml")