Class: WorkOS::PasswordStrengthErrorErrorBodyWithErrors
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- WorkOS::PasswordStrengthErrorErrorBodyWithErrors
- Defined in:
- lib/workos/user_management/password_strength_error_error_body_with_errors.rb
Constant Summary collapse
- HASH_ATTRS =
{ code: :code, message: :message, errors: :errors }.freeze
Instance Attribute Summary collapse
-
#code ⇒ Object
Returns the value of attribute code.
-
#errors ⇒ Object
Returns the value of attribute errors.
-
#message ⇒ Object
Returns the value of attribute message.
Instance Method Summary collapse
-
#initialize(json) ⇒ PasswordStrengthErrorErrorBodyWithErrors
constructor
A new instance of PasswordStrengthErrorErrorBodyWithErrors.
Constructor Details
#initialize(json) ⇒ PasswordStrengthErrorErrorBodyWithErrors
Returns a new instance of PasswordStrengthErrorErrorBodyWithErrors.
18 19 20 21 22 23 |
# File 'lib/workos/user_management/password_strength_error_error_body_with_errors.rb', line 18 def initialize(json) hash = self.class.normalize(json) @code = hash[:code] @message = hash[:message] @errors = (hash[:errors] || []).map { |item| item ? WorkOS::ErrorBodyWithCode.new(item) : nil } end |
Instance Attribute Details
#code ⇒ Object
Returns the value of attribute code.
13 14 15 |
# File 'lib/workos/user_management/password_strength_error_error_body_with_errors.rb', line 13 def code @code end |
#errors ⇒ Object
Returns the value of attribute errors.
13 14 15 |
# File 'lib/workos/user_management/password_strength_error_error_body_with_errors.rb', line 13 def errors @errors end |
#message ⇒ Object
Returns the value of attribute message.
13 14 15 |
# File 'lib/workos/user_management/password_strength_error_error_body_with_errors.rb', line 13 def @message end |