feat: Added detailed message for permission error and clean up english language from unused strings.

This commit is contained in:
Marco Rodolfi
2023-06-26 08:53:41 +02:00
parent ef9afa8cbc
commit 3e64e53cd7
5 changed files with 17 additions and 13 deletions
@@ -210,6 +210,9 @@ const FilePicker: FunctionComponent<FilePickerProps> = ({
case theError.match(/\[WinError\s3.*/i)?.input:
setError(FileErrorTypes.FileNotFound);
break;
case theError.match(/\[Errno\s13.*/i)?.input:
setError(FileErrorTypes.PermissionDenied);
break;
default:
setRawError(theError);
setError(FileErrorTypes.Unknown);