pl-api: fix fallback display_name

Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
This commit is contained in:
marcin mikołajczak 2024-10-09 20:11:25 +02:00
parent e5728edb4e
commit 8456f29d83
2 changed files with 2 additions and 2 deletions

View file

@ -51,7 +51,7 @@ const preprocessAccount = (account: any) => {
...(pick(account.other_settings || {}), ['birthday', 'location']),
__meta: pick(account, ['pleroma', 'source']),
...account,
display_name: account.display_name.trim() || username,
display_name: account.display_name?.trim() || username,
roles: account.roles?.length ? account.roles : filterBadges(account.pleroma?.tags),
source: account.source
? { ...(pick(account.pleroma?.source || {}, [

View file

@ -1,6 +1,6 @@
{
"name": "pl-api",
"version": "0.0.41",
"version": "0.0.42",
"type": "module",
"homepage": "https://github.com/mkljczk/pl-fe/tree/fork/packages/pl-api",
"repository": {