Using Entries instead of []Entry

This commit is contained in:
Deluan
2016-03-14 11:42:33 -04:00
parent 393d6fb2dc
commit 0ee070b38c
3 changed files with 6 additions and 6 deletions
+2 -2
View File
@@ -25,7 +25,7 @@ func (p playlists) GetAll() (*domain.Playlists, error) {
type PlaylistInfo struct {
Id string
Name string
Entries []Entry
Entries Entries
}
func (p playlists) Get(id string) (*PlaylistInfo, error) {
@@ -39,7 +39,7 @@ func (p playlists) Get(id string) (*PlaylistInfo, error) {
}
pinfo := &PlaylistInfo{Id: pl.Id, Name: pl.Name}
pinfo.Entries = make([]Entry, len(pl.Tracks))
pinfo.Entries = make(Entries, len(pl.Tracks))
// TODO Optimize: Get all tracks at once
for i, mfId := range pl.Tracks {