mirror of
https://github.com/navidrome/navidrome.git
synced 2025-04-05 21:47:36 +03:00
Enable a couple of linters
This commit is contained in:
parent
d6c70554b3
commit
26188e6d8a
3 changed files with 7 additions and 3 deletions
|
@ -1,8 +1,14 @@
|
||||||
linters:
|
linters:
|
||||||
enable:
|
enable:
|
||||||
|
- bodyclose
|
||||||
- goimports
|
- goimports
|
||||||
- unconvert
|
- goprintffuncname
|
||||||
- gosec
|
- gosec
|
||||||
|
- interfacer
|
||||||
|
- misspell
|
||||||
|
- rowserrcheck
|
||||||
|
- unconvert
|
||||||
|
- whitespace
|
||||||
|
|
||||||
issues:
|
issues:
|
||||||
exclude-rules:
|
exclude-rules:
|
||||||
|
|
|
@ -181,7 +181,6 @@ func (g *listGenerator) GetNowPlaying(ctx context.Context) (Entries, error) {
|
||||||
entries[i].MinutesAgo = int(time.Since(np.Start).Minutes())
|
entries[i].MinutesAgo = int(time.Since(np.Start).Minutes())
|
||||||
entries[i].PlayerId = np.PlayerId
|
entries[i].PlayerId = np.PlayerId
|
||||||
entries[i].PlayerName = np.PlayerName
|
entries[i].PlayerName = np.PlayerName
|
||||||
|
|
||||||
}
|
}
|
||||||
return entries, nil
|
return entries, nil
|
||||||
}
|
}
|
||||||
|
|
|
@ -38,7 +38,6 @@ type Router struct {
|
||||||
func New(browser engine.Browser, cover engine.Cover, listGenerator engine.ListGenerator, users engine.Users,
|
func New(browser engine.Browser, cover engine.Cover, listGenerator engine.ListGenerator, users engine.Users,
|
||||||
playlists engine.Playlists, ratings engine.Ratings, scrobbler engine.Scrobbler, search engine.Search,
|
playlists engine.Playlists, ratings engine.Ratings, scrobbler engine.Scrobbler, search engine.Search,
|
||||||
streamer engine.MediaStreamer, players engine.Players) *Router {
|
streamer engine.MediaStreamer, players engine.Players) *Router {
|
||||||
|
|
||||||
r := &Router{Browser: browser, Cover: cover, ListGenerator: listGenerator, Playlists: playlists,
|
r := &Router{Browser: browser, Cover: cover, ListGenerator: listGenerator, Playlists: playlists,
|
||||||
Ratings: ratings, Scrobbler: scrobbler, Search: search, Users: users, Streamer: streamer, Players: players}
|
Ratings: ratings, Scrobbler: scrobbler, Search: search, Users: users, Streamer: streamer, Players: players}
|
||||||
r.mux = r.routes()
|
r.mux = r.routes()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue