mirror of
https://codeberg.org/yeentown/barkey
synced 2024-11-23 01:25:12 +00: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}`;
|
||||
let acct = user.username;
|
||||
let acctUrl = `https://${user.host || this.config.host}/@${user.username}`;
|
||||
const acctUri = `https://${this.config.host}/@${user.id}`;
|
||||
if (user.host) {
|
||||
acct = `${user.username}@${user.host}`;
|
||||
acctUrl = `https://${user.host}/@${user.username}`;
|
||||
|
@ -150,6 +151,7 @@ export class MastoConverters {
|
|||
statuses_count: user.notesCount,
|
||||
note: profile?.description ?? '',
|
||||
url: user.uri ?? acctUrl,
|
||||
uri: user.uri ?? acctUri,
|
||||
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',
|
||||
header: user.bannerUrl ? user.bannerUrl : 'https://dev.joinsharkey.org/static-assets/transparent.png',
|
||||
|
|
Loading…
Reference in a new issue