formatted the 'db' script using vscode
[plcapi.git] / PLC / Methods / DeleteSession.py
index c2654a5..9ad5bd6 100644 (file)
@@ -1,4 +1,3 @@
-# $Id#
 import time
 
 from PLC.Method import Method
@@ -19,11 +18,11 @@ class DeleteSession(Method):
 
 
     def call(self, auth):
-        assert auth.has_key('session')
+        assert 'session' in auth
 
         sessions = Sessions(self.api, [auth['session']])
         if not sessions:
-            raise PLCAPIError, "No such session"
+            raise PLCAPIError("No such session")
         session = sessions[0]
 
         session.delete()