GodsDevProject commited on
Commit
ba29169
·
verified ·
1 Parent(s): 9b94564

Delete saved.py

Browse files
Files changed (1) hide show
  1. saved.py +0 -12
saved.py DELETED
@@ -1,12 +0,0 @@
1
- import json, hashlib, time
2
-
3
- _STORE = {}
4
-
5
- def save_search(query, sources):
6
- payload = {"q": query, "s": sources, "t": int(time.time())}
7
- key = hashlib.sha256(json.dumps(payload).encode()).hexdigest()[:12]
8
- _STORE[key] = payload
9
- return key
10
-
11
- def load_search(key):
12
- return _STORE.get(key)