@xuda.io/drive_module 1.1.839 → 1.1.841
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 +8 -1
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -1440,7 +1440,7 @@ exports.upload_drive_file = async function (req, job_id, headers, file_obj) {
|
|
|
1440
1440
|
}
|
|
1441
1441
|
};
|
|
1442
1442
|
exports.check_drive_file = async function (req, job_id, headers, file_obj) {
|
|
1443
|
-
const { type, drive_type, app_id, uid, file_path } = req;
|
|
1443
|
+
const { type = "file", drive_type, app_id, uid, file_path } = req;
|
|
1444
1444
|
|
|
1445
1445
|
var master_app_id;
|
|
1446
1446
|
|
|
@@ -1448,6 +1448,13 @@ exports.check_drive_file = async function (req, job_id, headers, file_obj) {
|
|
|
1448
1448
|
master_app_id = await _common.get_project_app_id(app_id, true);
|
|
1449
1449
|
}
|
|
1450
1450
|
|
|
1451
|
+
let selector = {
|
|
1452
|
+
docType: "workspace_drive",
|
|
1453
|
+
originalname: path.basename(file_path),
|
|
1454
|
+
file_path: path.dirname(file_path),
|
|
1455
|
+
stat: 3,
|
|
1456
|
+
};
|
|
1457
|
+
|
|
1451
1458
|
switch (drive_type) {
|
|
1452
1459
|
case "studio": {
|
|
1453
1460
|
const target_dir = path.join(_conf[`studio_drive_path`], master_app_id);
|