summaryrefslogtreecommitdiff
path: root/device_auth.py
diff options
context:
space:
mode:
authorDmitrii Morozov <snoopdesigns@gmail.com>2024-05-07 17:15:25 +0200
committerDmitrii Morozov <snoopdesigns@gmail.com>2024-05-07 17:15:25 +0200
commitee3e87a6ec19878d56e8f386b20c58e4d9b211b3 (patch)
treec111165b0310581abeea0cecbfd9dabe2933e0d9 /device_auth.py
parentcfa79cbbaf42a8f74a2cd4bca4d1d495b4d597f1 (diff)
Modules
Diffstat (limited to 'device_auth.py')
-rw-r--r--device_auth.py22
1 files changed, 0 insertions, 22 deletions
diff --git a/device_auth.py b/device_auth.py
deleted file mode 100644
index 4d46918..0000000
--- a/device_auth.py
+++ /dev/null
@@ -1,22 +0,0 @@
-import json
-import os
-
-__filename__ = 'device-auth.json'
-
-class DeviceAuth:
-
- def device_auth_file_exists(self):
- return os.path.isfile(__filename__)
-
- def get_device_auth_details(self):
- if os.path.isfile(__filename__):
- with open(__filename__, 'r') as fp:
- return json.load(fp)
- return {}
-
- def store_device_auth_details(self, email, details):
- existing = self.get_device_auth_details()
- existing[email] = details
-
- with open(__filename__, 'w') as fp:
- json.dump(existing, fp) \ No newline at end of file