Files
radiantwave-legacy/internal/db/queries.go
T
NeilClack 6fd5ec919c fix(db): stabilize connection settings and explicitly define AppConfig table name
- Set SQL connection idle limit to 1 to reduce resource usage
- Explicitly define AppConfig table name to prevent GORM pluralization issues
2026-06-26 22:49:51 -05:00

12 lines
209 B
Go

package db
import "gorm.io/gorm"
func GetConfig(db *gorm.DB) (*AppConfig, error) {
var appConfig AppConfig
if err := db.First(&appConfig).Error; err != nil {
return nil, err
}
return &appConfig, nil
}