diff --git a/spec/DecodeEventsSpec.hs b/spec/DecodeEventsSpec.hs index 79915ec..013f697 100644 --- a/spec/DecodeEventsSpec.hs +++ b/spec/DecodeEventsSpec.hs @@ -5801,6 +5801,7 @@ pushEventFixture = PushEvent , whUserType = OwnerUser , whUserIsAdminOfSite = False } + , evPushInstallation = Nothing } pushEventFixtureWithoutSender :: PushEvent @@ -5923,7 +5924,11 @@ pushEventFixtureWithoutSender = whOrgDescription = "Plurality Media" } ), - evPushSender = Nothing + evPushSender = Nothing, + evPushInstallation = Just $ HookChecksInstallation + { whChecksInstallationId = 17816238 + , whChecksInstallationNodeId = "MDIzklOdGunVcFm0WauSW9z5GFdsGb0FW9uaTMgM3zcNjg4=" + } } releaseEventFixture :: ReleaseEvent diff --git a/src/GitHub/Data/Webhooks/Events.hs b/src/GitHub/Data/Webhooks/Events.hs index f4a132d..2281680 100644 --- a/src/GitHub/Data/Webhooks/Events.hs +++ b/src/GitHub/Data/Webhooks/Events.hs @@ -1119,6 +1119,7 @@ data PushEvent = PushEvent , evPushOrganization :: !(Maybe HookOrganization) -- | In very rare cases, the sender may be missing. , evPushSender :: !(Maybe HookUser) + , evPushInstallation :: !(Maybe HookChecksInstallation) } deriving (Eq, Show, Typeable, Data, Generic) @@ -1575,6 +1576,7 @@ instance FromJSON PushEvent where <*> o .: "repository" <*> o .:? "organization" <*> o .:? "sender" + <*> o .:? "installation" instance FromJSON ReleaseEvent where parseJSON = withObject "ReleaseEvent" $ \o -> ReleaseEvent