Use the Str facade

This commit is contained in:
James Brooks 2016-04-27 14:37:17 +01:00
parent 97e5fa07fa
commit 067018cf47

View File

@ -19,6 +19,7 @@ use Illuminate\Support\Facades\Config;
use Illuminate\Support\Facades\Lang;
use Illuminate\Support\Facades\Redirect;
use Illuminate\Support\Facades\Session;
use Illuminate\Support\Facades\Str;
use Illuminate\Support\Facades\View;
class SettingsController extends Controller
@ -248,7 +249,7 @@ class SettingsController extends Controller
return Redirect::to($redirectUrl)->withErrors($file->getErrorMessage());
}
if (!starts_with($file->getMimeType(), 'image/')) {
if (!Str::startsWith($file->getMimeType(), 'image/')) {
return Redirect::to($redirectUrl)->withErrors(trans('dashboard.settings.app-setup.images-only'));
}