mirror of
https://activitypub.software/TransFem-org/Sharkey.git
synced 2024-12-14 01:50:45 +01:00
upd: provide uri on accounts
This commit is contained in:
parent
7ba8529141
commit
a5fccab128
1 changed files with 2 additions and 0 deletions
|
@ -133,6 +133,7 @@ export class MastoConverters {
|
||||||
const fqn = `${user.username}@${user.host ?? this.config.hostname}`;
|
const fqn = `${user.username}@${user.host ?? this.config.hostname}`;
|
||||||
let acct = user.username;
|
let acct = user.username;
|
||||||
let acctUrl = `https://${user.host || this.config.host}/@${user.username}`;
|
let acctUrl = `https://${user.host || this.config.host}/@${user.username}`;
|
||||||
|
const acctUri = `https://${this.config.host}/@${user.id}`;
|
||||||
if (user.host) {
|
if (user.host) {
|
||||||
acct = `${user.username}@${user.host}`;
|
acct = `${user.username}@${user.host}`;
|
||||||
acctUrl = `https://${user.host}/@${user.username}`;
|
acctUrl = `https://${user.host}/@${user.username}`;
|
||||||
|
@ -150,6 +151,7 @@ export class MastoConverters {
|
||||||
statuses_count: user.notesCount,
|
statuses_count: user.notesCount,
|
||||||
note: profile?.description ?? '',
|
note: profile?.description ?? '',
|
||||||
url: user.uri ?? acctUrl,
|
url: user.uri ?? acctUrl,
|
||||||
|
uri: user.uri ?? acctUri,
|
||||||
avatar: user.avatarUrl ? user.avatarUrl : 'https://dev.joinsharkey.org/static-assets/avatar.png',
|
avatar: user.avatarUrl ? user.avatarUrl : 'https://dev.joinsharkey.org/static-assets/avatar.png',
|
||||||
avatar_static: user.avatarUrl ? user.avatarUrl : 'https://dev.joinsharkey.org/static-assets/avatar.png',
|
avatar_static: user.avatarUrl ? user.avatarUrl : 'https://dev.joinsharkey.org/static-assets/avatar.png',
|
||||||
header: user.bannerUrl ? user.bannerUrl : 'https://dev.joinsharkey.org/static-assets/transparent.png',
|
header: user.bannerUrl ? user.bannerUrl : 'https://dev.joinsharkey.org/static-assets/transparent.png',
|
||||||
|
|
Loading…
Reference in a new issue