diff options
author | Chris <ccbrown112@gmail.com> | 2017-10-09 10:16:14 -0700 |
---|---|---|
committer | Joram Wilander <jwawilander@gmail.com> | 2017-10-09 13:16:14 -0400 |
commit | 0f66b6e72621842467d0e368b95ee58f485d4ace (patch) | |
tree | 444f9210a151cb735fe0502d4bb47c324592c0e6 /store/sqlstore/team_store.go | |
parent | 70e5f00241473c27a3008959ce08832c75e76ba8 (diff) | |
download | chat-0f66b6e72621842467d0e368b95ee58f485d4ace.tar.gz chat-0f66b6e72621842467d0e368b95ee58f485d4ace.tar.bz2 chat-0f66b6e72621842467d0e368b95ee58f485d4ace.zip |
store/sqlstore cleanup and postgres tests (#7595)
* sqlstore cleanup / postgres tests
* remove stopped containers
* cmd/platform compile fix
* remove test-postgres target from makefile
Diffstat (limited to 'store/sqlstore/team_store.go')
-rw-r--r-- | store/sqlstore/team_store.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/store/sqlstore/team_store.go b/store/sqlstore/team_store.go index c819ec61a..da63992dd 100644 --- a/store/sqlstore/team_store.go +++ b/store/sqlstore/team_store.go @@ -266,7 +266,7 @@ func (s SqlTeamStore) GetAllTeamListing() store.StoreChannel { return store.Do(func(result *store.StoreResult) { query := "SELECT * FROM Teams WHERE AllowOpenInvite = 1" - if *utils.Cfg.SqlSettings.DriverName == model.DATABASE_DRIVER_POSTGRES { + if s.DriverName() == model.DATABASE_DRIVER_POSTGRES { query = "SELECT * FROM Teams WHERE AllowOpenInvite = true" } @@ -289,7 +289,7 @@ func (s SqlTeamStore) GetAllTeamPageListing(offset int, limit int) store.StoreCh return store.Do(func(result *store.StoreResult) { query := "SELECT * FROM Teams WHERE AllowOpenInvite = 1 LIMIT :Limit OFFSET :Offset" - if *utils.Cfg.SqlSettings.DriverName == model.DATABASE_DRIVER_POSTGRES { + if s.DriverName() == model.DATABASE_DRIVER_POSTGRES { query = "SELECT * FROM Teams WHERE AllowOpenInvite = true LIMIT :Limit OFFSET :Offset" } |