diff --git a/conf/configuration.go b/conf/configuration.go index c5b4c6179..2636fbf94 100644 --- a/conf/configuration.go +++ b/conf/configuration.go @@ -57,7 +57,6 @@ type configOptions struct { SearchFullString bool RecentlyAddedByModTime bool PreferSortTags bool - AppendSubtitle bool IgnoredArticles string IndexGroups string FFmpegPath string @@ -133,6 +132,7 @@ type scannerOptions struct { } type subsonicOptions struct { + AppendSubtitle bool ArtistParticipations bool DefaultReportRealPath bool LegacyClients string @@ -447,7 +447,6 @@ func init() { viper.SetDefault("searchfullstring", false) viper.SetDefault("recentlyaddedbymodtime", false) viper.SetDefault("prefersorttags", false) - viper.SetDefault("appendsubtitle", true) viper.SetDefault("ignoredarticles", "The El La Los Las Le Les Os As O A") viper.SetDefault("indexgroups", "A B C D E F G H I J K L M N O P Q R S T U V W X-Z(XYZ) [Unknown]([)") viper.SetDefault("ffmpegpath", "") @@ -494,6 +493,7 @@ func init() { viper.SetDefault("scanner.watcherwait", consts.DefaultWatcherWait) viper.SetDefault("scanner.scanonstartup", true) + viper.SetDefault("subsonic.appendsubtitle", true) viper.SetDefault("subsonic.artistparticipations", false) viper.SetDefault("subsonic.defaultreportrealpath", false) viper.SetDefault("subsonic.legacyclients", "DSub") diff --git a/model/mediafile.go b/model/mediafile.go index fda1c784b..795657466 100644 --- a/model/mediafile.go +++ b/model/mediafile.go @@ -93,7 +93,7 @@ type MediaFile struct { } func (mf MediaFile) FullTitle() string { - if conf.Server.AppendSubtitle && mf.Tags[TagSubtitle] != nil { + if conf.Server.Subsonic.AppendSubtitle && mf.Tags[TagSubtitle] != nil { return fmt.Sprintf("%s (%s)", mf.Title, mf.Tags[TagSubtitle][0]) } return mf.Title diff --git a/model/tag_mappings.go b/model/tag_mappings.go index 76b54df17..3215feb35 100644 --- a/model/tag_mappings.go +++ b/model/tag_mappings.go @@ -55,7 +55,7 @@ func (c TagConf) SplitTagValue(values []string) []string { type TagType string const ( - TagTypeInteger TagType = "integer" + TagTypeInteger TagType = "int" TagTypeFloat TagType = "float" TagTypeDate TagType = "date" TagTypeUUID TagType = "uuid"