mirror of
https://github.com/flarum/core.git
synced 2025-10-28 22:07:33 +01:00
Use Laravel's class-based Str and Arr helpers
Starting with version 5.9, the global funtions will be deprecated. * https://laravel-news.com/laravel-5-8-deprecates-string-and-array-helpers * https://github.com/laravel/framework/pull/26898
This commit is contained in:
@@ -14,6 +14,7 @@ namespace Flarum\Update\Controller;
|
||||
use Exception;
|
||||
use Flarum\Database\Console\MigrateCommand;
|
||||
use Flarum\Foundation\Application;
|
||||
use Illuminate\Support\Arr;
|
||||
use Psr\Http\Message\ResponseInterface;
|
||||
use Psr\Http\Message\ServerRequestInterface as Request;
|
||||
use Psr\Http\Server\RequestHandlerInterface;
|
||||
@@ -49,7 +50,7 @@ class UpdateController implements RequestHandlerInterface
|
||||
{
|
||||
$input = $request->getParsedBody();
|
||||
|
||||
if (array_get($input, 'databasePassword') !== $this->app->config('database.password')) {
|
||||
if (Arr::get($input, 'databasePassword') !== $this->app->config('database.password')) {
|
||||
return new HtmlResponse('Incorrect database password.', 500);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user