@xuda.io/account_module 1.2.239 → 1.2.240

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.mjs +30 -0
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -1122,6 +1122,36 @@ export const get_contacts = async function (req) {
1122
1122
  opt.selector.name = { $regex: `(?i)${name}` };
1123
1123
  }
1124
1124
 
1125
+ if (typeof search !== 'undefined') {
1126
+ opt.selector['$or'] = [
1127
+ {
1128
+ _id: {
1129
+ $regex: `${req.log_search}`,
1130
+ },
1131
+ },
1132
+ {
1133
+ req_body: {
1134
+ $regex: `(?i)${req.log_search}`,
1135
+ },
1136
+ },
1137
+ {
1138
+ client_headers: {
1139
+ $regex: `(?i)${req.log_search}`,
1140
+ },
1141
+ },
1142
+ {
1143
+ response_data: {
1144
+ $regex: `(?i)${req.log_search}`,
1145
+ },
1146
+ },
1147
+ {
1148
+ method: {
1149
+ $eq: req.log_search,
1150
+ },
1151
+ },
1152
+ ];
1153
+ }
1154
+
1125
1155
  if (skip) {
1126
1156
  opt.skip = skip;
1127
1157
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/account_module",
3
- "version": "1.2.239",
3
+ "version": "1.2.240",
4
4
  "description": "Xuda Account Server Module",
5
5
  "main": "index.mjs",
6
6
  "dependencies": {