sqlx: optimize ams initial for sqlc feature

pull/351/head
Michael Li 2 years ago
parent 59edb16621
commit 6890f4f5fc
No known key found for this signature in database

@ -93,7 +93,7 @@ func TweetSearchService() core.TweetSearchService {
func newAuthorizationManageService() (s core.AuthorizationManageService) { func newAuthorizationManageService() (s core.AuthorizationManageService) {
if cfg.If("Gorm") { if cfg.If("Gorm") {
s = jinzhu.NewAuthorizationManageService() s = jinzhu.NewAuthorizationManageService()
} else if cfg.If("Sqlx") && cfg.If("MySQL") { } else if cfg.If("Sqlx") {
s = sakila.NewAuthorizationManageService() s = sakila.NewAuthorizationManageService()
} else if cfg.If("Sqlc") && (cfg.If("Postgres") || cfg.If("PostgreSQL")) { } else if cfg.If("Sqlc") && (cfg.If("Postgres") || cfg.If("PostgreSQL")) {
s = slonik.NewAuthorizationManageService() s = slonik.NewAuthorizationManageService()

Loading…
Cancel
Save