[MM-16389] Add icon_emoji parameter to webhooks (#11586)

[MM-16389] Add icon_emoji field to posts from incoming webhooks

To be used to substitute the profile picture on posts.
Этот коммит содержится в:
krjn
2019-07-17 09:01:18 +00:00
коммит произвёл Hanzei
родитель 1da858ac4c
Коммит dd30488a09
14 изменённых файлов: 279 добавлений и 93 удалений

Просмотреть файл

@@ -31,6 +31,11 @@ func inSystemEmoji(emojiName string) bool {
return ok
}
func GetSystemEmojiId(emojiName string) (string, bool) {
id, found := SystemEmojis[emojiName]
return id, found
}
func (emoji *Emoji) IsValid() *AppError {
if len(emoji.Id) != 26 {
return NewAppError("Emoji.IsValid", "model.emoji.id.app_error", nil, "", http.StatusBadRequest)