Этот коммит содержится в:
Chris
2017-09-06 17:12:54 -05:00
коммит произвёл GitHub
родитель b84bd21089
Коммит 1adfd0e9be
178 изменённых файлов: 2919 добавлений и 2806 удалений

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

@@ -7,16 +7,16 @@ import (
"github.com/mattermost/platform/model"
)
func GetAudits(userId string, limit int) (model.Audits, *model.AppError) {
if result := <-Srv.Store.Audit().Get(userId, 0, limit); result.Err != nil {
func (a *App) GetAudits(userId string, limit int) (model.Audits, *model.AppError) {
if result := <-a.Srv.Store.Audit().Get(userId, 0, limit); result.Err != nil {
return nil, result.Err
} else {
return result.Data.(model.Audits), nil
}
}
func GetAuditsPage(userId string, page int, perPage int) (model.Audits, *model.AppError) {
if result := <-Srv.Store.Audit().Get(userId, page*perPage, perPage); result.Err != nil {
func (a *App) GetAuditsPage(userId string, page int, perPage int) (model.Audits, *model.AppError) {
if result := <-a.Srv.Store.Audit().Get(userId, page*perPage, perPage); result.Err != nil {
return nil, result.Err
} else {
return result.Data.(model.Audits), nil