diff options
author | Joram Wilander <jwawilander@gmail.com> | 2017-04-12 16:29:42 -0400 |
---|---|---|
committer | Harrison Healey <harrisonmhealey@gmail.com> | 2017-04-12 16:29:42 -0400 |
commit | 8b8aa2ca3c803b26fb4a1ba5f249111739376494 (patch) | |
tree | 9fa13e99e60a9effc12bad964b13a3c23fab795e /store/sql_user_store.go | |
parent | 03502cf73b8513a40877b1ac5726523974661d4d (diff) | |
download | chat-8b8aa2ca3c803b26fb4a1ba5f249111739376494.tar.gz chat-8b8aa2ca3c803b26fb4a1ba5f249111739376494.tar.bz2 chat-8b8aa2ca3c803b26fb4a1ba5f249111739376494.zip |
Refactor OAuth 2.0 code into app layer (#6037)
Diffstat (limited to 'store/sql_user_store.go')
-rw-r--r-- | store/sql_user_store.go | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/store/sql_user_store.go b/store/sql_user_store.go index 52e45ed7d..5ea04155d 100644 --- a/store/sql_user_store.go +++ b/store/sql_user_store.go @@ -389,8 +389,7 @@ func (us SqlUserStore) Get(id string) StoreChannel { if obj, err := us.GetReplica().Get(model.User{}, id); err != nil { result.Err = model.NewLocAppError("SqlUserStore.Get", "store.sql_user.get.app_error", nil, "user_id="+id+", "+err.Error()) } else if obj == nil { - result.Err = model.NewLocAppError("SqlUserStore.Get", MISSING_ACCOUNT_ERROR, nil, "user_id="+id) - result.Err.StatusCode = http.StatusNotFound + result.Err = model.NewAppError("SqlUserStore.Get", MISSING_ACCOUNT_ERROR, nil, "user_id="+id, http.StatusNotFound) } else { result.Data = obj.(*model.User) } |