mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-10 00:34:50 +00:00
Update AccountTransformer, I need some coffee
This commit is contained in:
parent
403163f12f
commit
1ff7ba909e
1 changed files with 1 additions and 1 deletions
|
@ -17,7 +17,7 @@ class AccountTransformer extends Fractal\TransformerAbstract
|
|||
$local = $profile->domain == null;
|
||||
$is_admin = !$local ? false : $profile->user->is_admin;
|
||||
$acct = $local ? $profile->username : substr($profile->username, 1);
|
||||
$username = $local ? $profile->username : explode('@', $profile->username)[0];
|
||||
$username = $local ? $profile->username : explode('@', $acct)[0];
|
||||
return [
|
||||
'id' => (string) $profile->id,
|
||||
'username' => $username,
|
||||
|
|
Loading…
Reference in a new issue