Changed arrow function so that the parameter is clearly shown inside a parentheses.
Changed the alert text a bit to make it more clear that they need to select an audio or video file to upload.
This commit is contained in:
parent
efb0f72a88
commit
1d38c59643
@ -49,8 +49,8 @@ function validateFile() {
|
|||||||
|
|
||||||
if (file) {
|
if (file) {
|
||||||
const fileType = file.type;
|
const fileType = file.type;
|
||||||
if (!allowedMimeTypes.some(type => fileType.startsWith(type))) {
|
if (!allowedMimeTypes.some((type) => fileType.startsWith(type))) {
|
||||||
alert('File type is not an audio or video file.\nPlease upload an audio or video file.');
|
alert('File type is not an audio or video file.\nPlease select an audio or video file to upload.');
|
||||||
fileInput.value = '';
|
fileInput.value = '';
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user