mirror of
https://github.com/gabehf/Koito.git
synced 2026-03-07 13:38:15 -08:00
feat: v0.0.3
This commit is contained in:
parent
7ff317756f
commit
3250a4ec3f
21 changed files with 322 additions and 374 deletions
|
|
@ -110,6 +110,11 @@ func loadConfig(getenv func(string) string, version string) (*config, error) {
|
|||
if cfg.musicBrainzUrl == "" {
|
||||
cfg.musicBrainzUrl = defaultMusicBrainzUrl
|
||||
}
|
||||
|
||||
if cfg.musicBrainzUrl == defaultMusicBrainzUrl && cfg.musicBrainzRateLimit != 1 {
|
||||
return nil, fmt.Errorf("loadConfig: invalid configuration: %s cannot be altered when %s is default", MUSICBRAINZ_RATE_LIMIT_ENV, MUSICBRAINZ_URL_ENV)
|
||||
}
|
||||
|
||||
if parseBool(getenv(ENABLE_LBZ_RELAY_ENV)) {
|
||||
cfg.lbzRelayEnabled = true
|
||||
cfg.lbzRelayToken = getenv(LBZ_RELAY_TOKEN_ENV)
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ import (
|
|||
"github.com/jackc/pgx/v5/pgtype"
|
||||
)
|
||||
|
||||
const searchItemLimit = 5
|
||||
const searchItemLimit = 8
|
||||
const substringSearchLength = 6
|
||||
|
||||
func (d *Psql) SearchArtists(ctx context.Context, q string) ([]*models.Artist, error) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue