From b0cf3e2f15132af6dccd25ef0f019abcd0d510fe Mon Sep 17 00:00:00 2001 From: Asaf Gartner Date: Tue, 22 Mar 2022 21:00:50 +0200 Subject: [PATCH] Probably fixed issue with twitch --- src/twitch/rest.go | 2 +- src/twitch/twitch.go | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/src/twitch/rest.go b/src/twitch/rest.go index 03960ba..4284af2 100644 --- a/src/twitch/rest.go +++ b/src/twitch/rest.go @@ -199,7 +199,7 @@ func getEventSubscriptions(ctx context.Context) ([]twitchEventSub, error) { type twitchResponse struct { Data []eventSub `json:"data"` Pagination *struct { - After string `json:"after"` + After string `json:"cursor"` } `json:"pagination"` } diff --git a/src/twitch/twitch.go b/src/twitch/twitch.go index 1f9dc46..4b4ad4f 100644 --- a/src/twitch/twitch.go +++ b/src/twitch/twitch.go @@ -212,7 +212,6 @@ func syncWithTwitch(ctx context.Context, dbConn *pgxpool.Pool, updateAll bool) { return } p.EndBlock() - log.Info().Interface("Subscriptions", subscriptions).Msg("Got subs from twitch") const ( EventSubNone = 0 // No event of this type found @@ -271,7 +270,6 @@ func syncWithTwitch(ctx context.Context, dbConn *pgxpool.Pool, updateAll bool) { for twitchID, evStatuses := range streamerEventSubs { for evType, isSubbed := range evStatuses { if !isSubbed { - log.Info().Str("TwitchID", twitchID).Str("Type", evType).Msg("Subscribing") err = subscribeToEvent(ctx, evType, twitchID) if err != nil { log.Error().Err(err).Msg("Error while monitoring twitch")