Merge pull request #2215 from pixelfed/staging

Fix IG Import
This commit is contained in:
daniel 2020-05-27 17:12:19 -06:00 committed by GitHub
commit 1f042dd02f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View file

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

View file

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