fix timeserver config loading

pull/150/merge
Pete Matsyburka 2 years ago
parent 5fd018df46
commit 541b025ad0

@ -75,7 +75,14 @@ module Accounts
if Docuseal.multitenant? if Docuseal.multitenant?
Docuseal::TIMESERVER_URL Docuseal::TIMESERVER_URL
else else
EncryptedConfig.find_by(account:, key: EncryptedConfig::TIMESTAMP_SERVER_URL_KEY)&.value url = EncryptedConfig.find_by(account:, key: EncryptedConfig::TIMESTAMP_SERVER_URL_KEY)&.value
unless Docuseal.multitenant?
url ||=
Account.order(:id).first.encrypted_configs.find_by(key: EncryptedConfig::TIMESTAMP_SERVER_URL_KEY)&.value
end
url
end.presence end.presence
end end

Loading…
Cancel
Save