1
0
Fork 0
mirror of synced 2024-06-02 10:54:44 +12:00

feat: add missing error codes

This commit is contained in:
Christy Jacob 2022-02-27 18:26:46 +04:00
parent f8a445294c
commit 0bcd8bff23
2 changed files with 3 additions and 2 deletions

View file

@ -384,7 +384,7 @@ App::patch('/v1/functions/:functionId/deployments/:deploymentId')
}
if ($build->getAttribute('status') !== 'ready') {
throw new Exception('Build not ready', 400);
throw new Exception('Build not ready', 400, Exception::BUILD_NOT_READY);
}
$schedule = $function->getAttribute('schedule', '');

View file

@ -1,5 +1,6 @@
<?php
use Appwrite\Extend\Exception;
use Utopia\App;
/**
@ -18,6 +19,6 @@ App::post('/v1/graphql')
->label('scope', 'public')
->action(
function () {
throw new Exception('GraphQL support is coming soon!', 502);
throw new Exception('GraphQL support is coming soon!', 502, Exception::GENERAL_SERVER_ERROR);
}
);