aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorMarcel Klehr <mklehr@gmx.net>2023-10-26 11:41:21 +0200
committerMarcel Klehr <mklehr@gmx.net>2023-10-26 11:41:21 +0200
commitb9985bfd6699034900e0c31f2e245f9b44a5f498 (patch)
tree8e922bbf77d8ab413578bc46b38d618c12683208 /lib
parent35bf7fc94e01f2104078928989d581583095690f (diff)
downloadnextcloud-server-b9985bfd6699034900e0c31f2e245f9b44a5f498.tar.gz
nextcloud-server-b9985bfd6699034900e0c31f2e245f9b44a5f498.zip
fix(TextToImage): Add missing task status update
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/TextToImage/Manager.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/private/TextToImage/Manager.php b/lib/private/TextToImage/Manager.php
index 7af3f37651d..1553fed7545 100644
--- a/lib/private/TextToImage/Manager.php
+++ b/lib/private/TextToImage/Manager.php
@@ -199,6 +199,12 @@ class Manager implements IManager {
}
}
+ $task->setStatus(Task::STATUS_FAILED);
+ try {
+ $this->taskMapper->update(DbTask::fromPublicTask($task));
+ } catch (Exception $e) {
+ $this->logger->warning('Failed to update database after Text2Image error', ['exception' => $e]);
+ }
throw new TaskFailureException('Could not run task');
}