@xuda.io/drive_module 1.1.1001 → 1.1.1003
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 +7 -6
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -801,7 +801,6 @@ exports.delete_drive_files = async function (req, job_id, headers) {
|
|
|
801
801
|
};
|
|
802
802
|
}
|
|
803
803
|
|
|
804
|
-
let doc_ret;
|
|
805
804
|
for await (const file of files_arr) {
|
|
806
805
|
let doc = await get_drive_doc(
|
|
807
806
|
"file",
|
|
@@ -816,7 +815,12 @@ exports.delete_drive_files = async function (req, job_id, headers) {
|
|
|
816
815
|
case "studio": {
|
|
817
816
|
debugger;
|
|
818
817
|
const app_id_reference = await _common.get_project_app_id(app_id);
|
|
819
|
-
const
|
|
818
|
+
const target_dir = path.join(
|
|
819
|
+
_conf[`studio_drive_path`],
|
|
820
|
+
app_id_reference,
|
|
821
|
+
ile.file_path
|
|
822
|
+
);
|
|
823
|
+
const ret = rimraf.sync(target_dir); // delete the file
|
|
820
824
|
|
|
821
825
|
if (doc.type === "file") {
|
|
822
826
|
doc.ts = Date.now();
|
|
@@ -873,10 +877,7 @@ exports.delete_drive_files = async function (req, job_id, headers) {
|
|
|
873
877
|
break;
|
|
874
878
|
}
|
|
875
879
|
case "user": {
|
|
876
|
-
misc_module.rsync_drive_resources_to_remote_servers(
|
|
877
|
-
"user",
|
|
878
|
-
doc_ret.data.uid
|
|
879
|
-
);
|
|
880
|
+
misc_module.rsync_drive_resources_to_remote_servers("user", uid);
|
|
880
881
|
break;
|
|
881
882
|
}
|
|
882
883
|
default:
|