@xuda.io/drive_module 1.1.927 → 1.1.929

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 +5 -5
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -1696,8 +1696,8 @@ exports.check_drive_file = async function (req, job_id, headers, file_obj) {
1696
1696
  };
1697
1697
  };
1698
1698
 
1699
- const ocr_drive_file = async function (doc) {
1700
- const { drive_type, app_id, uid, file_path, originalname } = doc;
1699
+ const ocr_drive_file = async function (app_id, doc) {
1700
+ const { drive_type, uid, file_path, originalname } = doc;
1701
1701
 
1702
1702
  // const _region = process.env.XUDA_HOSTNAME;
1703
1703
  let target_file = get_file_url(
@@ -1938,12 +1938,12 @@ exports.run_drive_pending_ocr = async function (req) {
1938
1938
  try {
1939
1939
  var opt = {
1940
1940
  selector: { docType: "user_drive", ocr_stat: 1, stat: 3 },
1941
- // limit: 1,
1941
+ limit: 1,
1942
1942
  };
1943
1943
 
1944
1944
  const user_drive_res = await db_module.find_couch_query("xuda_drive", opt);
1945
1945
  for await (let doc of user_drive_res.docs) {
1946
- await ocr_drive_file(doc);
1946
+ await ocr_drive_file(null, doc);
1947
1947
  }
1948
1948
 
1949
1949
  let selector = {
@@ -1976,7 +1976,7 @@ exports.run_drive_pending_ocr = async function (req) {
1976
1976
  const app_drive_res = await db_module.find_app_couch_query(app._id, opt);
1977
1977
  for await (let doc of app_drive_res.docs) {
1978
1978
  console.log(opt, doc);
1979
- await ocr_drive_file(doc);
1979
+ await ocr_drive_file(app._id, doc);
1980
1980
  }
1981
1981
  }
1982
1982
  } catch (err) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/drive_module",
3
- "version": "1.1.927",
3
+ "version": "1.1.929",
4
4
  "description": "Xuda Drive Server Module",
5
5
  "main": "index.js",
6
6
  "dependencies": {