Use empty slice instead of null slice
All checks were successful
the build was successful

This commit is contained in:
Peter Stuifzand 2018-08-28 21:29:18 +02:00
parent 89a50821d4
commit dc5f9883f2
WARNING! Although there is a key with this ID in the database it does not verify this commit! This commit is SUSPICIOUS.
GPG Key ID: 374322D56E5209E8

View File

@ -301,15 +301,15 @@ func (b *memoryBackend) TimelineGet(before, after, channel string) (microsub.Tim
conn := pool.Get()
defer conn.Close()
items := []microsub.Item{}
log.Printf("TimelineGet %s\n", channel)
feeds, err := b.FollowGetList(channel)
if err != nil {
return microsub.Timeline{}, err
return microsub.Timeline{Items: items}, err
}
log.Println(feeds)
var items []microsub.Item
zchannelKey := fmt.Sprintf("zchannel:%s:posts", channel)
afterScore := "-inf"