@xuda.io/account_module 1.2.793 → 1.2.795

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 +22 -2
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -1256,8 +1256,12 @@ const get_contact_pattern = async function (doc) {
1256
1256
  ret = `fictional-avatar-pattern.png`;
1257
1257
  break;
1258
1258
 
1259
+ case 'authentic profile':
1260
+ ret = `authentic-avatar-pattern.png`;
1261
+ break;
1262
+
1259
1263
  default:
1260
- ret = `my-pattern.png`;
1264
+ ret = `xu-pattern.png`;
1261
1265
  break;
1262
1266
  }
1263
1267
  }
@@ -1265,7 +1269,23 @@ const get_contact_pattern = async function (doc) {
1265
1269
  const shared_from_uid_ret = await get_account_name({ uid_query: doc.shared_from_uid });
1266
1270
  ret = shared_from_uid_ret.data.profile_avatar;
1267
1271
  } else if (doc.contact_uid) {
1268
- ret = `xu-pattern.png`;
1272
+ switch (doc.avatar_source) {
1273
+ case 'fictional':
1274
+ ret = `fictional-avatar-pattern.png`;
1275
+ break;
1276
+
1277
+ case 'ai profile':
1278
+ ret = `fictional-avatar-pattern.png`;
1279
+ break;
1280
+
1281
+ case 'authentic profile':
1282
+ ret = `authentic-avatar-pattern.png`;
1283
+ break;
1284
+
1285
+ default:
1286
+ ret = `xu-pattern.png`;
1287
+ break;
1288
+ }
1269
1289
  } else {
1270
1290
  switch (doc.source) {
1271
1291
  case 'email': {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/account_module",
3
- "version": "1.2.793",
3
+ "version": "1.2.795",
4
4
  "description": "Xuda Account Server Module",
5
5
  "main": "index.mjs",
6
6
  "dependencies": {