diff --git a/migrations/brute-force-prevention.php b/migrations/0001-brute-force-prevention.php similarity index 100% rename from migrations/brute-force-prevention.php rename to migrations/0001-brute-force-prevention.php diff --git a/src/Web/Actions/Update/PostUpdateAction.php b/src/Web/Actions/Update/PostUpdateAction.php index 0b3601359..6a5bd6596 100755 --- a/src/Web/Actions/Update/PostUpdateAction.php +++ b/src/Web/Actions/Update/PostUpdateAction.php @@ -2,7 +2,9 @@ namespace App\Web\Actions\Update; +use App\Database\Migrations\Migrator; use App\Web\Actions\Action; +use JsonException; use Nyholm\Psr7\Response; use Psr\Http\Message\ResponseInterface; use Throwable; @@ -12,7 +14,7 @@ class PostUpdateAction extends UpdateAction { /** * {@inheritDoc} - * @throws \JsonException + * @throws JsonException */ protected function action(): ResponseInterface { @@ -31,6 +33,7 @@ protected function action(): ResponseInterface $zipStream->open($updatePath); $zipStream->extractTo(__ROOT__); $zipStream->close(); + Migrator::migrate(); unlink(__ROOT__ . '/update.lock'); } catch (Throwable $exception) { return $this->render(