Update AvatarController, fix store bug

This commit is contained in:
Daniel Supernault 2022-02-09 19:57:12 -07:00
parent 9f455c6529
commit 7fa9d4dc1b
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7
2 changed files with 2 additions and 2 deletions

View file

@ -183,7 +183,7 @@ class BaseApiController extends Controller
{
abort_if(!$request->user(), 403);
$this->validate($request, [
'upload' => 'required|mimetypes:jpeg,png,gif|max:'.config('pixelfed.max_avatar_size'),
'upload' => 'required|mimetypes:image/jpeg,image/jpg,image/png|max:'.config('pixelfed.max_avatar_size'),
]);
try {

View file

@ -19,7 +19,7 @@ class AvatarController extends Controller
public function store(Request $request)
{
$this->validate($request, [
'avatar' => 'required|mimetypes:jpeg,png|max:'.config('pixelfed.max_avatar_size'),
'avatar' => 'required|mimetypes:image/jpeg,image/jpg,image/png|max:'.config('pixelfed.max_avatar_size'),
]);
try {