mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-05-01 11:19:32 -05:00
fix result on empty task
This commit is contained in:
parent
b507403d0e
commit
d0d696db77
@ -614,7 +614,7 @@ class TasksViewSerializer(serializers.ModelSerializer):
|
||||
|
||||
def get_result(self, obj):
|
||||
result = ""
|
||||
if hasattr(obj, "attempted_task"):
|
||||
if hasattr(obj, "attempted_task") and obj.attempted_task:
|
||||
result = obj.attempted_task.result
|
||||
return result
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user