Make upload size globally available #2828

This commit is contained in:
James Cole
2020-03-19 08:43:52 +01:00
parent 75afe35e98
commit 6129b9d25c
4 changed files with 8 additions and 15 deletions

View File

@@ -46,10 +46,6 @@ class CreateController extends Controller
{
parent::__construct();
$maxFileSize = app('steam')->phpBytes(ini_get('upload_max_filesize'));
$maxPostSize = app('steam')->phpBytes(ini_get('post_max_size'));
$uploadSize = min($maxFileSize, $maxPostSize);
app('view')->share('uploadSize', $uploadSize);
$this->middleware(
static function ($request, $next) {
app('view')->share('title', (string) trans('firefly.transactions'));