Skip to content

Commit 832c168

Browse files
committed
Update webhook handler docs
1 parent 38c55af commit 832c168

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

docs/usage/webhooks.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,9 @@ module WebhookHandler
2121
extend ShopifyAPI::Webhooks::WebhookHandler
2222

2323
class << self
24-
def handle_webhook(data:)
25-
puts "Received webhook! topic: #{data.topic} shop: #{data.shop} body: #{data.body} webhook_id: #{data.webhook_id} api_version: #{data.api_version"
24+
def handle(data:)
25+
puts "Received webhook! topic: #{data.topic} shop: #{data.shop} body: #{data.body} webhook_id: #{data.webhook_id} api_version: #{data.api_version}"
26+
perform_later(topic: data.topic, shop_domain: data.shop, webhook: data.body)
2627
end
2728
end
2829
end

0 commit comments

Comments
 (0)