fix nil pointer
continuous-integration/drone/push Build is passing Details

This commit is contained in:
Jay 2021-02-22 11:03:17 +08:00
parent 01c9402eac
commit 08e0607a88
1 changed files with 3 additions and 0 deletions

View File

@ -103,6 +103,9 @@ func hasChannel(id string, c *context.Context) *model.TwitchChannel {
fmt.Println("channels :: ", chs)
for _, v := range chs {
if v == nil {
continue
}
if v.ID == id {
return v
}