소스 검색

Allow bank login while debugging

Eren Yilmaz 6 년 전
부모
커밋
ac5a6692c2
1개의 변경된 파일4개의 추가작업 그리고 2개의 파일을 삭제
  1. 4 2
      model.py

+ 4 - 2
model.py

@@ -86,8 +86,10 @@ def used_key_count():
 def login(username, password):
 def login(username, password):
     connect()
     connect()
 
 
-    # do not allow login as bank
-    if password == '':
+    # do not allow login as bank or with empty password
+    if username == 'bank' and not debug:
+        return None
+    if password == '' and not debug:
         return None
         return None
 
 
     cursor.execute('''
     cursor.execute('''