Merge remote-tracking branch 'origin/master' into gs-master

Conflicts:
 	app/javascript/mastodon/locales/en.json
 	app/javascript/mastodon/locales/ja.json
 	app/javascript/mastodon/locales/pl.json
 	app/views/accounts/_header.html.haml
This commit is contained in:
David Yip
2018-04-01 20:24:50 -05:00
82 changed files with 753 additions and 37 deletions

View File

@ -352,6 +352,10 @@ class Account < ApplicationRecord
end
end
def emojis
CustomEmoji.from_text(note, domain)
end
before_create :generate_keys
before_validation :normalize_domain
before_validation :prepare_contents, if: :local?

View File

@ -41,6 +41,10 @@ class RemoteProfile
@header ||= link_href_from_xml(author, 'header')
end
def emojis
@emojis ||= author.xpath('./xmlns:link[@rel="emoji"]', xmlns: OStatus::TagManager::XMLNS)
end
def locked?
scope == 'private'
end