Skip to content
This repository was archived by the owner on May 16, 2019. It is now read-only.

Commit b4f2879

Browse files
committed
Republish moderator status
1 parent 0f91434 commit b4f2879

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

market/network.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1106,6 +1106,11 @@ def update_listings(self):
11061106
c.delete(True)
11071107
if contract_hash in data:
11081108
del data[contract_hash]
1109+
guid = KeyChain(self.db).guid
1110+
moderator = Profile(self.db).get().moderator
1111+
if (guid not in data or time.time() - data[guid] > 500000) and moderator:
1112+
self.make_moderator()
1113+
data[guid] = time.time()
11091114
with open(fname, 'w') as f:
11101115
pickle.dump(data, f)
11111116
except Exception:

0 commit comments

Comments
 (0)