Don't send ok result when update is queued
This commit is contained in:
parent
636813c603
commit
628cc992e9
1 changed files with 0 additions and 3 deletions
|
@ -73,9 +73,6 @@ class FileRequest(object):
|
||||||
|
|
||||||
if cmd == "update":
|
if cmd == "update":
|
||||||
event = "%s update %s %s" % (self.connection.id, params["site"], params["inner_path"])
|
event = "%s update %s %s" % (self.connection.id, params["site"], params["inner_path"])
|
||||||
if not RateLimit.isAllowed(event): # There was already an update for this file in the last 10 second
|
|
||||||
time.sleep(5)
|
|
||||||
self.response({"ok": "File update queued"})
|
|
||||||
# If called more than once within 15 sec only keep the last update
|
# If called more than once within 15 sec only keep the last update
|
||||||
RateLimit.callAsync(event, max(self.connection.bad_actions, 15), self.actionUpdate, params)
|
RateLimit.callAsync(event, max(self.connection.bad_actions, 15), self.actionUpdate, params)
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue