Rename render acct (#5)

This commit is contained in:
marihachi 2021-05-15 17:42:48 +09:00 committed by GitHub
parent 148730dac3
commit a4d5faa789
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -9,6 +9,6 @@ export function parse(acct: string): Acct {
return { username: split[0], host: split[1] || null };
}
export function render(acct: Acct): string {
export function toString(acct: Acct): string {
return acct.host == null ? acct.username : `${acct.username}@${acct.host}`;
}