@xuda.io/drive_module 1.1.498 → 1.1.500

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.
Files changed (2) hide show
  1. package/index.js +12 -12
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -1859,18 +1859,12 @@ exports.get_drive_size = async function (req) {
1859
1859
  let size = 0;
1860
1860
  // validate_drive_type(drive_type);
1861
1861
 
1862
- var ref;
1863
- if (drive_type === "user") {
1864
- ref = uid;
1865
- } else {
1866
- ref = await _common.get_project_app_id(app_id, true);
1867
- }
1868
-
1869
- const directoryPath = path.join(
1870
- _conf[`${drive_type}_drive_path`],
1871
- ref,
1872
- "/"
1873
- );
1862
+ // var ref;
1863
+ // if (drive_type === "user") {
1864
+ // ref = uid;
1865
+ // } else {
1866
+ // ref = await _common.get_project_app_id(app_id, true);
1867
+ // }
1874
1868
 
1875
1869
  switch (drive_type) {
1876
1870
  case "user":
@@ -1879,6 +1873,12 @@ exports.get_drive_size = async function (req) {
1879
1873
  break;
1880
1874
 
1881
1875
  default:
1876
+ const app_id_master = await _common.get_project_app_id(app_id, true);
1877
+ const directoryPath = path.join(
1878
+ _conf[`${drive_type}_drive_path`],
1879
+ ref,
1880
+ "/"
1881
+ );
1882
1882
  size = await get_folder_size(directoryPath, drive_type, app_id);
1883
1883
  break;
1884
1884
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/drive_module",
3
- "version": "1.1.498",
3
+ "version": "1.1.500",
4
4
  "description": "Xuda Drive Server Module",
5
5
  "main": "index.js",
6
6
  "dependencies": {