@xuda.io/drive_module 1.1.1258 → 1.1.1260
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.mjs +5 -1
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -677,8 +677,9 @@ export const create_drive_folder = async (req, job_id, headers) => {
|
|
|
677
677
|
file_path: doc.file_path,
|
|
678
678
|
type: doc.type,
|
|
679
679
|
};
|
|
680
|
-
const check_existing_file_ret = await check_drive_file(check_req);
|
|
681
680
|
debugger;
|
|
681
|
+
const check_existing_file_ret = await check_drive_file(check_req);
|
|
682
|
+
|
|
682
683
|
if (check_existing_file_ret.code < 0) {
|
|
683
684
|
throw new Error(check_existing_file_ret.data);
|
|
684
685
|
}
|
|
@@ -1218,6 +1219,9 @@ export const check_drive_file = async (req, job_id, headers, file_obj) => {
|
|
|
1218
1219
|
if (type === 'file') {
|
|
1219
1220
|
selector.originalname = path.basename(file_path);
|
|
1220
1221
|
}
|
|
1222
|
+
if (type === 'directory') {
|
|
1223
|
+
selector.folder_name = path.basename(file_path);
|
|
1224
|
+
}
|
|
1221
1225
|
|
|
1222
1226
|
switch (drive_type) {
|
|
1223
1227
|
case 'studio': {
|