Class: DemographicsPolicy

Inherits:
Struct
  • Object
show all
Defined in:
app/policies/demographics_policy.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#gender_identityObject

Returns the value of attribute gender_identity

Returns:

  • (Object)

    the current value of gender_identity



3
4
5
# File 'app/policies/demographics_policy.rb', line 3

def gender_identity
  @gender_identity
end

#userObject

Returns the value of attribute user

Returns:

  • (Object)

    the current value of user



3
4
5
# File 'app/policies/demographics_policy.rb', line 3

def user
  @user
end

Instance Method Details

#access?Boolean

Returns:

  • (Boolean)


4
5
6
# File 'app/policies/demographics_policy.rb', line 4

def access?
  user&.idme_uuid.present? || user&.logingov_uuid.present?
end

#access_update?Boolean

Returns:

  • (Boolean)


8
9
10
# File 'app/policies/demographics_policy.rb', line 8

def access_update?
  user&.idme_uuid.present? || user&.logingov_uuid.present?
end