lib/pact_broker/webhooks/service.rb in pact_broker-2.0.2 vs lib/pact_broker/webhooks/service.rb in pact_broker-2.0.3

- old
+ new

@@ -29,10 +29,11 @@ def self.find_by_uuid uuid webhook_repository.find_by_uuid uuid end def self.delete_by_uuid uuid + webhook_repository.delete_executions_by_webhook_uuid uuid webhook_repository.delete_by_uuid uuid end def self.delete_by_pacticipant pacticipant webhook_repository.delete_by_pacticipant pacticipant @@ -41,10 +42,12 @@ def self.find_all webhook_repository.find_all end def self.execute_webhook_now webhook - webhook.execute + webhook_execution_result = webhook.execute + webhook_repository.create_execution webhook, webhook_execution_result + webhook_execution_result end def self.find_by_consumer_and_provider consumer, provider webhook_repository.find_by_consumer_and_provider consumer, provider end