Skip to content

Commit

Permalink
Merge pull request #22 from mattermost-community/getUsersInChannel
Browse files Browse the repository at this point in the history
Use GetUsersInChannel instead of getUsers
  • Loading branch information
BenCookie95 authored Oct 2, 2024
2 parents 0458bbb + ef6c1e7 commit fea92cd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/plugin/plugin_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ func (p *Plugin) getAllChannelUsers(channelID string) []*model.User {
perPage := 100
allUsers := make([]*model.User, 0)
for {
users, appErr := p.API.GetUsers(&model.UserGetOptions{InChannelId: channelID, Page: page, PerPage: perPage})
users, appErr := p.API.GetUsersInChannel(channelID, "username", page, perPage)
if appErr != nil || len(users) == 0 {
break
}
Expand Down

0 comments on commit fea92cd

Please sign in to comment.