Skip to content

Commit

Permalink
models:file - fix incorrect action property name
Browse files Browse the repository at this point in the history
  • Loading branch information
MatteoCampinoti94 committed Nov 20, 2023
1 parent 8674d8e commit b34b110
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions acacore/models/file.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ def from_file(
file.action = file.action_data.reidentify.onfail
else:
file.action = "manual"
file.action_data = ActionData(manual=ManualAction(reasoning="Re-identify failure", process=""))
file.action_data = ActionData(manual=ManualAction(reason="Re-identify failure", process=""))
file.puid = file.signature = file.warning = None

if file.action_data and file.action_data.ignore and file.action_data.ignore.ignore_if:
Expand All @@ -141,13 +141,13 @@ def from_file(
or height < (ignore_if.pixel_height or 0)
):
file.action = "ignore"
file.action_data.ignore.reasoning = ignore_if.reason or file.action_data.ignore.reasoning
file.action_data.ignore.reason = ignore_if.reason or file.action_data.ignore.reason
elif file.is_binary and file.size < (ignore_if.binary_size or 0): # noqa: SIM114
file.action = "ignore"
file.action_data.ignore.reasoning = ignore_if.reason or file.action_data.ignore.reasoning
file.action_data.ignore.reason = ignore_if.reason or file.action_data.ignore.reason
elif file.size < (ignore_if.size or 0):
file.action = "ignore"
file.action_data.ignore.reasoning = ignore_if.reason or file.action_data.ignore.reasoning
file.action_data.ignore.reason = ignore_if.reason or file.action_data.ignore.reason

return file

Expand Down

0 comments on commit b34b110

Please sign in to comment.