refactor: improving the readability

This commit is contained in:
likui628 2024-04-02 16:25:35 +08:00
parent b28a46edcb
commit 6528dc45df
1 changed files with 7 additions and 7 deletions

View File

@ -195,9 +195,9 @@
//
item.response = {
code: 0,
message:"upload Success!",
url:get(ret, props.resultField)
}
message: 'upload Success!',
url: get(ret, props.resultField),
};
}
return {
success: true,
@ -216,7 +216,7 @@
//
async function handleStartUpload() {
const { maxNumber } = props;
if ((fileListRef.value.length + props.previewFileList?.length ?? 0) > maxNumber) {
if (fileListRef.value.length + props.previewFileList.length > maxNumber) {
return createMessage.warning(t('component.upload.maxNumber', [maxNumber]));
}
try {