APIv4 get /channels/{channel_id}/pinned (#5893)

Этот коммит содержится в:
Saturnino Abril
2017-03-30 00:09:05 +09:00
коммит произвёл Corey Hulen
родитель 64f80decaf
Коммит 8a31718db1
5 изменённых файлов: 102 добавлений и 0 удалений

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

@@ -1053,3 +1053,11 @@ func PermanentDeleteChannel(channel *model.Channel) *model.AppError {
return nil
}
func GetPinnedPosts(channelId string) (*model.PostList, *model.AppError) {
if result := <-Srv.Store.Channel().GetPinnedPosts(channelId); result.Err != nil {
return nil, result.Err
} else {
return result.Data.(*model.PostList), nil
}
}