fix webhook url on testing

pull/289/merge
Pete Matsyburka 1 year ago
parent c2051c156e
commit a729fd6234

@ -81,8 +81,8 @@ module Accounts
def load_webhook_url(account) def load_webhook_url(account)
configs = account.encrypted_configs.find_by(key: EncryptedConfig::WEBHOOK_URL_KEY) configs = account.encrypted_configs.find_by(key: EncryptedConfig::WEBHOOK_URL_KEY)
unless Docuseal.multitenant? if !configs && !Docuseal.multitenant? && !account.testing?
configs ||= Account.order(:id).first.encrypted_configs.find_by(key: EncryptedConfig::WEBHOOK_URL_KEY) configs = Account.order(:id).first.encrypted_configs.find_by(key: EncryptedConfig::WEBHOOK_URL_KEY)
end end
configs&.value.presence configs&.value.presence

Loading…
Cancel
Save