diff options
author | Martin Kraft <martinkraft@gmail.com> | 2018-05-17 07:53:16 -0400 |
---|---|---|
committer | Martin Kraft <martinkraft@gmail.com> | 2018-05-17 07:53:16 -0400 |
commit | 6f31d90e2f31ae597b83b2f845d5db938af8e38c (patch) | |
tree | 81c59b83ffb033df92ff7fba5ffaf3ba5fe7a3cf /app/auto_teams.go | |
parent | 319d61123a0418ea9caa9510b8ad1e9a302c7b93 (diff) | |
parent | 1f6c271b3bedd6656ae7155714423b1b39a669c1 (diff) | |
download | chat-6f31d90e2f31ae597b83b2f845d5db938af8e38c.tar.gz chat-6f31d90e2f31ae597b83b2f845d5db938af8e38c.tar.bz2 chat-6f31d90e2f31ae597b83b2f845d5db938af8e38c.zip |
Merge remote-tracking branch 'origin/master' into advanced-permissions-phase-2
Diffstat (limited to 'app/auto_teams.go')
-rw-r--r-- | app/auto_teams.go | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/app/auto_teams.go b/app/auto_teams.go index 9dce5bd15..e322e8c66 100644 --- a/app/auto_teams.go +++ b/app/auto_teams.go @@ -14,7 +14,7 @@ type TeamEnvironment struct { } type AutoTeamCreator struct { - client *model.Client + client *model.Client4 Fuzzy bool NameLength utils.Range NameCharset string @@ -24,7 +24,7 @@ type AutoTeamCreator struct { EmailCharset string } -func NewAutoTeamCreator(client *model.Client) *AutoTeamCreator { +func NewAutoTeamCreator(client *model.Client4) *AutoTeamCreator { return &AutoTeamCreator{ client: client, Fuzzy: false, @@ -57,11 +57,10 @@ func (cfg *AutoTeamCreator) createRandomTeam() (*model.Team, bool) { Type: model.TEAM_OPEN, } - result, err := cfg.client.CreateTeam(team) + createdTeam, err := cfg.client.CreateTeam(team) if err != nil { return nil, false } - createdTeam := result.Data.(*model.Team) return createdTeam, true } |