diff options
author | Joram Wilander <jwawilander@gmail.com> | 2017-01-13 15:17:50 -0500 |
---|---|---|
committer | Harrison Healey <harrisonmhealey@gmail.com> | 2017-01-13 15:17:50 -0500 |
commit | 0e2b321e6f5ab5983bc3428aa455dac7012c36ee (patch) | |
tree | c3919a284cf13ddcb66a6f482b1c9bbd9f34fc9b /api/command_logout.go | |
parent | 97558f6a6ec4c53fa69035fb430ead209d9c222d (diff) | |
download | chat-0e2b321e6f5ab5983bc3428aa455dac7012c36ee.tar.gz chat-0e2b321e6f5ab5983bc3428aa455dac7012c36ee.tar.bz2 chat-0e2b321e6f5ab5983bc3428aa455dac7012c36ee.zip |
Refactor and migrate more functions out of api into app package (#5063)
Diffstat (limited to 'api/command_logout.go')
-rw-r--r-- | api/command_logout.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/api/command_logout.go b/api/command_logout.go index 00375bb58..0eaa9a0ba 100644 --- a/api/command_logout.go +++ b/api/command_logout.go @@ -4,6 +4,7 @@ package api import ( + "github.com/mattermost/platform/app" "github.com/mattermost/platform/model" ) @@ -38,8 +39,7 @@ func (me *LogoutProvider) DoCommand(c *Context, args *model.CommandArgs, message // We can't actually remove the user's cookie from here so we just dump their session and let the browser figure it out if c.Session.Id != "" { - RevokeSessionById(c, c.Session.Id) - if c.Err != nil { + if err := app.RevokeSessionById(c.Session.Id); err != nil { return FAIL } return SUCCESS |