Update IG Import, remove hardcoded media size limit

This commit is contained in:
Daniel Supernault 2020-05-27 17:09:41 -06:00
parent 193027bdc7
commit 144678fc9c
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7
2 changed files with 3 additions and 2 deletions

View file

@ -69,8 +69,9 @@ trait Instagram
public function instagramStepOneStore(Request $request, $uuid)
{
$max = 'max:' . config('pixelfed.import.instagram.limits.size');
$this->validate($request, [
'media.*' => 'required|mimes:bin,jpeg,png,gif|max:500',
'media.*' => 'required|mimes:bin,jpeg,png,gif|'.$max,
//'mediajson' => 'required|file|mimes:json'
]);
$media = $request->file('media');

View file

@ -239,7 +239,7 @@ return [
'enabled' => env('IMPORT_INSTAGRAM', false),
'limits' => [
'posts' => (int) env('IMPORT_INSTAGRAM_POST_LIMIT', 100),
'size' => (int) env('IMPORT_INSTAGRAM_SIZE_LIMIT', 250)
'size' => (int) env('IMPORT_INSTAGRAM_SIZE_LIMIT', 5000)
]
]
],