diff options
author | Matt Jankowski <mjankowski@thoughtbot.com> | 2017-04-10 16:58:06 -0400 |
---|---|---|
committer | Eugen <eugen@zeonfederated.com> | 2017-04-10 22:58:06 +0200 |
commit | 0687ab8ae3c2573ba2aa1d37f62e3583d0c7ab01 (patch) | |
tree | 24ea1de1856ec7f203f6f89c5b8231a5d37da2cb /app/lib | |
parent | 64dbde0dbf8c5d3ce820f780644d46a6b18e6743 (diff) |
Clean up generation of account webfinger string (#1477)
* Consolidate webfinger string creation under Account#to_webfinger_s * Introduce Account#local_username_and_domain for consolidation
Diffstat (limited to 'app/lib')
-rw-r--r-- | app/lib/atom_serializer.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/lib/atom_serializer.rb b/app/lib/atom_serializer.rb index 845d38c92..68d2fce68 100644 --- a/app/lib/atom_serializer.rb +++ b/app/lib/atom_serializer.rb @@ -20,7 +20,7 @@ class AtomSerializer append_element(author, 'activity:object-type', TagManager::TYPES[:person]) append_element(author, 'uri', uri) append_element(author, 'name', account.username) - append_element(author, 'email', account.local? ? "#{account.acct}@#{Rails.configuration.x.local_domain}" : account.acct) + append_element(author, 'email', account.local? ? account.local_username_and_domain : account.acct) append_element(author, 'summary', account.note) append_element(author, 'link', nil, rel: :alternate, type: 'text/html', href: TagManager.instance.url_for(account)) append_element(author, 'link', nil, rel: :avatar, type: account.avatar_content_type, 'media:width': 120, 'media:height': 120, href: full_asset_url(account.avatar.url(:original))) |