more detailed error
This commit is contained in:
parent
763fe73eb7
commit
0afa1297e9
1 changed files with 1 additions and 1 deletions
|
@ -165,7 +165,7 @@ class ScoreControllerProvider implements ControllerProviderInterface
|
||||||
$filename = $file->getClientOriginalName();
|
$filename = $file->getClientOriginalName();
|
||||||
$ext = $file->getClientOriginalExtension();
|
$ext = $file->getClientOriginalExtension();
|
||||||
if($ext != 'jpg' || $file->getMimeType() != 'image/jpeg') {
|
if($ext != 'jpg' || $file->getMimeType() != 'image/jpeg') {
|
||||||
return new JsonResponse(['success' => false, 'message' => "Image not image/jpeg"], 400);
|
return new JsonResponse(['success' => false, 'message' => "Image not image/jpeg but " . $file->getMimeType() . " (".$ext.")"], 400);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue