Просмотр исходного кода

排他エラー時の例外ハンドリング処理を追加

develop
sosuke.iwabuchi 2 лет назад
Родитель
Сommit
d26eec7b5f
1 измененных файлов: 4 добавлений и 0 удалений
  1. +4
    -0
      app/Http/Controllers/Web/WebController.php

+ 4
- 0
app/Http/Controllers/Web/WebController.php Просмотреть файл

@@ -5,6 +5,7 @@ namespace App\Http\Controllers\Web;
use App\Codes\HTTPResultCode as ResultCode;
use App\Codes\UserRole;
use App\Exceptions\AppCommonException;
use App\Exceptions\ExclusiveException;
use App\Exceptions\GeneralErrorMessageException;
use Exception;
use Illuminate\Foundation\Auth\Access\AuthorizesRequests;
@@ -159,6 +160,9 @@ abstract class WebController extends BaseController
} catch (AppCommonException $e) {
logs()->error(sprintf("Appエラー:%s", $e->getMessage()));
return $this->failedResponse();
} catch (ExclusiveException $e) {
logs()->error(sprintf("排他エラー:%s", $e->getMessage()));
return $this->exclusiveErrorResponse();
} catch (LogicException $e) {
logs()->error([
sprintf("実装エラー:%s", $e->getMessage()),


Загрузка…
Отмена
Сохранить