update
This commit is contained in:
parent
6a07fa78dd
commit
ed14ddad0c
|
@ -404,7 +404,6 @@ export class UserEntityService implements OnModuleInit {
|
||||||
userRelations?: Map<MiUser['id'], UserRelation>,
|
userRelations?: Map<MiUser['id'], UserRelation>,
|
||||||
userMemos?: Map<MiUser['id'], string | null>,
|
userMemos?: Map<MiUser['id'], string | null>,
|
||||||
pinNotes?: Map<MiUser['id'], MiUserNotePining[]>,
|
pinNotes?: Map<MiUser['id'], MiUserNotePining[]>,
|
||||||
todayGetPoints?: number,
|
|
||||||
},
|
},
|
||||||
): Promise<Packed<S>> {
|
): Promise<Packed<S>> {
|
||||||
const opts = Object.assign({
|
const opts = Object.assign({
|
||||||
|
@ -508,7 +507,7 @@ export class UserEntityService implements OnModuleInit {
|
||||||
iconUrl: r.iconUrl,
|
iconUrl: r.iconUrl,
|
||||||
displayOrder: r.displayOrder,
|
displayOrder: r.displayOrder,
|
||||||
}))) : undefined,
|
}))) : undefined,
|
||||||
...(user.host == null ? { getPoints: profile!.getPoints } : {}),
|
...(user.host == null ? { getPoints: user.getPoints } : {}),
|
||||||
...(isDetailed ? {
|
...(isDetailed ? {
|
||||||
url: profile!.url,
|
url: profile!.url,
|
||||||
uri: user.uri,
|
uri: user.uri,
|
||||||
|
@ -603,9 +602,6 @@ export class UserEntityService implements OnModuleInit {
|
||||||
achievements: profile!.achievements,
|
achievements: profile!.achievements,
|
||||||
loggedInDays: profile!.loggedInDates.length,
|
loggedInDays: profile!.loggedInDates.length,
|
||||||
policies: this.roleService.getUserPolicies(user.id),
|
policies: this.roleService.getUserPolicies(user.id),
|
||||||
...(opts.todayGetPoints ? {
|
|
||||||
todayGetPoints: opts.todayGetPoints,
|
|
||||||
} : {}),
|
|
||||||
} : {}),
|
} : {}),
|
||||||
|
|
||||||
...(opts.includeSecrets ? {
|
...(opts.includeSecrets ? {
|
||||||
|
|
|
@ -83,7 +83,6 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
||||||
schema: 'MeDetailed',
|
schema: 'MeDetailed',
|
||||||
includeSecrets: isSecure,
|
includeSecrets: isSecure,
|
||||||
userProfile,
|
userProfile,
|
||||||
...(todayGetPoints && { todayGetPoints }),
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue