@xuda.io/drive_module 1.1.695 → 1.1.697
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.js +9 -2
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -2351,6 +2351,13 @@ exports.update_drive_file_tags = async function (req, job_id, headers) {
|
|
|
2351
2351
|
const { drive_type, app_id, uid, file_path, file_name, tags = [] } = req;
|
|
2352
2352
|
validate_drive_type(drive_type);
|
|
2353
2353
|
|
|
2354
|
+
let check_req = {
|
|
2355
|
+
app_id,
|
|
2356
|
+
uid,
|
|
2357
|
+
drive_type,
|
|
2358
|
+
file_name,
|
|
2359
|
+
file_path,
|
|
2360
|
+
};
|
|
2354
2361
|
const check_existing_file_ret = await module.exports.check_drive_file(
|
|
2355
2362
|
check_req
|
|
2356
2363
|
);
|
|
@@ -2394,11 +2401,11 @@ exports.update_drive_file_tags = async function (req, job_id, headers) {
|
|
|
2394
2401
|
doc.date_modified = Date.now();
|
|
2395
2402
|
} else {
|
|
2396
2403
|
if (drive_type === "studio") {
|
|
2397
|
-
const ext = path.extname(
|
|
2404
|
+
const ext = path.extname(file_name).toLowerCase();
|
|
2398
2405
|
doc = {
|
|
2399
2406
|
docType: `${drive_type}_drive`,
|
|
2400
2407
|
stat: 3,
|
|
2401
|
-
originalname:
|
|
2408
|
+
originalname: file_name,
|
|
2402
2409
|
uid,
|
|
2403
2410
|
type: "file",
|
|
2404
2411
|
date_created: Date.now(),
|