fix: handle no acct string

This commit is contained in:
Daniel Roe 2022-12-28 17:01:13 +01:00
parent abe6af40f3
commit 34dc2f7736
No known key found for this signature in database
GPG key ID: 22D5008E4F5D9B55
2 changed files with 3 additions and 3 deletions

View file

@ -41,7 +41,7 @@ export function getShortHandle({ acct }: Account) {
}
export function getServerName(account: Account) {
if (account.acct.includes('@'))
if (account.acct?.includes('@'))
return account.acct.split('@')[1]
// We should only lack the server name if we're on the same server as the account
return currentInstance.value?.uri || ''