Enable Last.fm scrobbling by default (still requires user's authorization)
This commit is contained in:
parent
92634a7408
commit
26bcf0b877
|
@ -228,7 +228,7 @@ func init() {
|
||||||
viper.SetDefault("devFastAccessCoverArt", false)
|
viper.SetDefault("devFastAccessCoverArt", false)
|
||||||
viper.SetDefault("devactivitypanel", true)
|
viper.SetDefault("devactivitypanel", true)
|
||||||
viper.SetDefault("devenableshare", false)
|
viper.SetDefault("devenableshare", false)
|
||||||
viper.SetDefault("devenablescrobble", false)
|
viper.SetDefault("devenablescrobble", true)
|
||||||
}
|
}
|
||||||
|
|
||||||
func InitConfig(cfgFile string) {
|
func InitConfig(cfgFile string) {
|
||||||
|
|
|
@ -207,7 +207,7 @@ var _ = Describe("serveIndex", func() {
|
||||||
serveIndex(ds, fs)(w, r)
|
serveIndex(ds, fs)(w, r)
|
||||||
|
|
||||||
config := extractAppConfig(w.Body.String())
|
config := extractAppConfig(w.Body.String())
|
||||||
Expect(config).To(HaveKeyWithValue("devEnableScrobble", false))
|
Expect(config).To(HaveKeyWithValue("devEnableScrobble", true))
|
||||||
})
|
})
|
||||||
|
|
||||||
It("sets the lastFMApiKey", func() {
|
It("sets the lastFMApiKey", func() {
|
||||||
|
|
|
@ -11,6 +11,7 @@ import {
|
||||||
useTranslate,
|
useTranslate,
|
||||||
} from 'react-admin'
|
} from 'react-admin'
|
||||||
import { Title } from '../common'
|
import { Title } from '../common'
|
||||||
|
import config from '../config'
|
||||||
|
|
||||||
const PlayerTitle = ({ record }) => {
|
const PlayerTitle = ({ record }) => {
|
||||||
const translate = useTranslate()
|
const translate = useTranslate()
|
||||||
|
@ -47,7 +48,9 @@ const PlayerEdit = (props) => (
|
||||||
]}
|
]}
|
||||||
/>
|
/>
|
||||||
<BooleanInput source="reportRealPath" fullWidth />
|
<BooleanInput source="reportRealPath" fullWidth />
|
||||||
<BooleanInput source="scrobbleEnabled" fullWidth />
|
{config.devEnableScrobble && (
|
||||||
|
<BooleanInput source="scrobbleEnabled" fullWidth />
|
||||||
|
)}
|
||||||
<TextField source="client" />
|
<TextField source="client" />
|
||||||
<TextField source="userName" />
|
<TextField source="userName" />
|
||||||
</SimpleForm>
|
</SimpleForm>
|
||||||
|
|
Loading…
Reference in New Issue