Class: SolidusNexio::Webhook
- Inherits:
-
ApplicationRecord
- Object
- ApplicationRecord
- SolidusNexio::Webhook
- Defined in:
- app/models/solidus_nexio/webhook.rb
Class Method Summary collapse
Class Method Details
.process(event_type, data) ⇒ Object
5 6 7 8 9 |
# File 'app/models/solidus_nexio/webhook.rb', line 5 def self.process(event_type, data) record = create(data: data) if SolidusNexio.config.save_webhooks SolidusNexio.config.webhooks.each { |service| service.call(event_type, data, record) } end |