itlab-internal-services 2.0.0 → 2.0.1

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.
@@ -17,13 +17,14 @@ class AvatarModel {
17
17
  const transform = {
18
18
  virtuals: true,
19
19
  transform: (_, ret) => {
20
+ const account = {
21
+ id: ret.id,
22
+ email: ret.email,
23
+ username: ret.username,
24
+ };
20
25
  if (ret.avatar)
21
- ret.avatar = `https://services.svi-itlab.com/account/avatar/${ret.id}`;
22
- delete ret._id;
23
- delete ret.__v;
24
- delete ret.createdAt;
25
- delete ret.updatedAt;
26
- return ret;
26
+ account.avatar = `https://services.svi-itlab.com/account/avatar/${ret.id}`;
27
+ return account;
27
28
  },
28
29
  };
29
30
  let AccountModel = class AccountModel extends mongoose_2.Document {
package/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "email": "timo.scheuermann@sv-informatik.de",
6
6
  "url": "https://timos.design"
7
7
  },
8
- "version": "2.0.0",
8
+ "version": "2.0.1",
9
9
  "type": "commonjs",
10
10
  "files": [
11
11
  "dist"