aboutsummaryrefslogtreecommitdiffstats
path: root/core/Controller/TextToImageApiController.php
diff options
context:
space:
mode:
Diffstat (limited to 'core/Controller/TextToImageApiController.php')
-rw-r--r--core/Controller/TextToImageApiController.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/core/Controller/TextToImageApiController.php b/core/Controller/TextToImageApiController.php
index 27833c0035d..45443347ee0 100644
--- a/core/Controller/TextToImageApiController.php
+++ b/core/Controller/TextToImageApiController.php
@@ -40,6 +40,7 @@ use OCP\DB\Exception;
use OCP\Files\NotFoundException;
use OCP\IL10N;
use OCP\IRequest;
+use OCP\TextToImage\Exception\TaskFailureException;
use OCP\TextToImage\Exception\TaskNotFoundException;
use OCP\TextToImage\Task;
use OCP\TextToImage\IManager;
@@ -95,7 +96,7 @@ class TextToImageApiController extends \OCP\AppFramework\OCSController {
try {
try {
$this->textToImageManager->runOrScheduleTask($task);
- } catch (\RuntimeException) {
+ } catch (TaskFailureException) {
// noop
}