Remove unkeyed composite literals.
This was done to keep in accordance with `go vet`.
This commit is contained in:
parent
bbf85de692
commit
d46beb0f7d
2 changed files with 6 additions and 2 deletions
|
@ -84,7 +84,9 @@ func TestTorrentPurging(t *testing.T) {
|
||||||
|
|
||||||
func TestStalePeerPurging(t *testing.T) {
|
func TestStalePeerPurging(t *testing.T) {
|
||||||
cfg := config.DefaultConfig
|
cfg := config.DefaultConfig
|
||||||
cfg.Announce = config.Duration{10 * time.Millisecond}
|
cfg.Announce = config.Duration{
|
||||||
|
Duration: 10 * time.Millisecond,
|
||||||
|
}
|
||||||
|
|
||||||
srv, err := setupTracker(&cfg)
|
srv, err := setupTracker(&cfg)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
|
@ -24,5 +24,7 @@ func (tkr *Tracker) HandleScrape(scrape *models.Scrape, w Writer) (err error) {
|
||||||
torrents = append(torrents, torrent)
|
torrents = append(torrents, torrent)
|
||||||
}
|
}
|
||||||
|
|
||||||
return w.WriteScrape(&models.ScrapeResponse{torrents})
|
return w.WriteScrape(&models.ScrapeResponse{
|
||||||
|
Files: torrents,
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue