Rename optionalRemove to optionalRemoved and accept hash only by id
This commit is contained in:
parent
17be72e55e
commit
f162987a4f
2 changed files with 13 additions and 15 deletions
|
@ -14,6 +14,7 @@ if "_" not in locals():
|
|||
|
||||
bigfile_sha512_cache = {}
|
||||
|
||||
|
||||
@PluginManager.registerTo("UiWebsocket")
|
||||
class UiWebsocketPlugin(object):
|
||||
def __init__(self, *args, **kwargs):
|
||||
|
@ -228,7 +229,7 @@ class UiWebsocketPlugin(object):
|
|||
if not row:
|
||||
return self.response(to, {"error": "Not found in content.db"})
|
||||
|
||||
removed = site.content_manager.optionalRemove(inner_path, row["hash_id"], row["size"])
|
||||
removed = site.content_manager.optionalRemoved(inner_path, row["hash_id"], row["size"])
|
||||
# if not removed:
|
||||
# return self.response(to, {"error": "Not found in hash_id: %s" % row["hash_id"]})
|
||||
|
||||
|
@ -242,7 +243,6 @@ class UiWebsocketPlugin(object):
|
|||
|
||||
self.response(to, "ok")
|
||||
|
||||
|
||||
# Limit functions
|
||||
|
||||
def actionOptionalLimitStats(self, to):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue