mirror of
https://github.com/snipe/snipe-it.git
synced 2025-01-12 14:27:33 -08:00
Clearer reporting on import
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
parent
3855b74161
commit
54ef469d98
|
@ -49,10 +49,11 @@ class ImportController extends Controller
|
|||
if (!in_array($file->getMimeType(), array(
|
||||
'application/vnd.ms-excel',
|
||||
'text/csv',
|
||||
'application/csv',
|
||||
'text/plain',
|
||||
'text/comma-separated-values',
|
||||
'text/tsv'))) {
|
||||
$results['error']='File type must be CSV';
|
||||
$results['error']='File type must be CSV. Uploaded file is '.$file->getMimeType();
|
||||
return response()->json(Helper::formatStandardApiResponse('error', null, $results['error']), 500);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue