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