@xuda.io/account_module 1.2.779 → 1.2.781
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.mjs +8 -6
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -941,15 +941,9 @@ export const search_users = async function (req) {
|
|
|
941
941
|
docs.push(doc);
|
|
942
942
|
}
|
|
943
943
|
|
|
944
|
-
// debugger
|
|
945
944
|
return {
|
|
946
945
|
code: 1,
|
|
947
946
|
data: docs,
|
|
948
|
-
// data: ret.docs.map((e) => {
|
|
949
|
-
// const { socket_id, ...rest } = e;
|
|
950
|
-
|
|
951
|
-
// return { _id: e._id, ...rest.account_info, online: e.socket_id ? true : false };
|
|
952
|
-
// }),
|
|
953
947
|
};
|
|
954
948
|
} catch (e) {
|
|
955
949
|
return {
|
|
@@ -1251,6 +1245,14 @@ const get_contact_pattern = async function (doc) {
|
|
|
1251
1245
|
if (doc.account_type === 'business') {
|
|
1252
1246
|
ret = doc.profile_picture;
|
|
1253
1247
|
} else {
|
|
1248
|
+
switch (doc.avatar_source) {
|
|
1249
|
+
case 'fictional':
|
|
1250
|
+
ret = `fictional-avatar-pattern.png`;
|
|
1251
|
+
break;
|
|
1252
|
+
|
|
1253
|
+
default:
|
|
1254
|
+
break;
|
|
1255
|
+
}
|
|
1254
1256
|
ret = `my-pattern.png`;
|
|
1255
1257
|
}
|
|
1256
1258
|
} else if (doc.shared_from_uid) {
|