diff options
author | Holly 'Frinkel' Lotor <admin@frinkel.tech> | 2020-01-20 11:54:21 -0500 |
---|---|---|
committer | Holly 'Frinkel' Lotor <admin@frinkel.tech> | 2020-01-20 16:56:53 -0500 |
commit | 259f0b15fc10470c00c57d88aec07617b5ee6ece (patch) | |
tree | 4a7bc0176181b760cab594a65c388713632cb95d /app | |
parent | b0630ddc8261250c5edbf2907648695041649e98 (diff) |
Merge first smoke test
Diffstat (limited to 'app')
-rw-r--r-- | app/lib/tag_manager.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/app/lib/tag_manager.rb b/app/lib/tag_manager.rb index c88cf4994..fbe03e10f 100644 --- a/app/lib/tag_manager.rb +++ b/app/lib/tag_manager.rb @@ -36,4 +36,15 @@ class TagManager TagManager.instance.web_domain?(domain) end + + def url_for(target) + return target.url if target.respond_to?(:local?) && !target.local? + + case target.object_type + when :person + short_account_url(target) + when :note, :comment, :activity + short_account_status_url(target.account, target) + end + end end |