mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-25 04:46:40 +07:00
nof
This commit is contained in:
parent
92f097d161
commit
d46906175b
2 changed files with 2 additions and 0 deletions
|
@ -45,4 +45,5 @@ const ImageEditor = connect(
|
||||||
mapStateToProps,
|
mapStateToProps,
|
||||||
mapDispatchToProps
|
mapDispatchToProps
|
||||||
)(ImageEditorUnconnected);
|
)(ImageEditorUnconnected);
|
||||||
|
|
||||||
export { ImageEditor };
|
export { ImageEditor };
|
||||||
|
|
|
@ -36,6 +36,7 @@ function* uploadWorker(file: File, temp_id: UUID) {
|
||||||
|
|
||||||
return yield call(promise, { temp_id, file });
|
return yield call(promise, { temp_id, file });
|
||||||
}
|
}
|
||||||
|
|
||||||
function* uploadFile({ file, temp_id }: IFileWithUUID) {
|
function* uploadFile({ file, temp_id }: IFileWithUUID) {
|
||||||
if (!file.type || !VALIDATORS.IS_IMAGE_MIME(file.type)) {
|
if (!file.type || !VALIDATORS.IS_IMAGE_MIME(file.type)) {
|
||||||
return { error: 'File_Not_Image', status: HTTP_RESPONSES.BAD_REQUEST, data: {} };
|
return { error: 'File_Not_Image', status: HTTP_RESPONSES.BAD_REQUEST, data: {} };
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue