fix: saml association

This commit is contained in:
Shivam Mishra
2025-08-25 13:56:55 +05:30
parent d06e2cfd98
commit f5c45c35f2
+1 -5
View File
@@ -1,10 +1,6 @@
module Enterprise::Account
extend ActiveSupport::Concern
included do
has_one :saml_settings, class_name: 'AccountSamlSettings', dependent: :destroy
end
# TODO: Remove this when we upgrade administrate gem to the latest version
# this is a temporary method since current administrate doesn't support virtual attributes
def manually_managed_features; end
@@ -23,6 +19,6 @@ module Enterprise::Account
end
def saml_enabled?
saml_settings&.saml_enabled? || false
AccountSamlSettings.find_by(account: self)&.saml_enabled? || false
end
end