|
@@ -143,7 +143,7 @@ func (a *AheadStruct) Ahead() (eri *entity.AheadRecommend) {
|
|
if eri.More {
|
|
if eri.More {
|
|
ri := 0
|
|
ri := 0
|
|
if len(eri.List)-int(count) > 1 {
|
|
if len(eri.List)-int(count) > 1 {
|
|
- rand.New(rand.NewSource(time.Now().UnixNano())).Intn(len(eri.List) - int(count) - 1)
|
|
|
|
|
|
+ ri = rand.New(rand.NewSource(time.Now().UnixNano())).Intn(len(eri.List) - int(count) - 1)
|
|
}
|
|
}
|
|
eri.List = eri.List[ri : ri+int(count)]
|
|
eri.List = eri.List[ri : ri+int(count)]
|
|
}
|
|
}
|