Method: EilamTest::UserCreate#list_invalid_properties
- Defined in:
- lib/eilam_test/models/user_create.rb
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons. Usually used together with valid?
159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 |
# File 'lib/eilam_test/models/user_create.rb', line 159 def list_invalid_properties invalid_properties = Array.new if !@email.nil? && @email.to_s.length > 254 invalid_properties.push('invalid value for "email", the character length must be smaller than or equal to 254.') end if !@first_name.nil? && @first_name.to_s.length > 150 invalid_properties.push('invalid value for "first_name", the character length must be smaller than or equal to 150.') end if !@last_name.nil? && @last_name.to_s.length > 150 invalid_properties.push('invalid value for "last_name", the character length must be smaller than or equal to 150.') end if !@password.nil? && @password.to_s.length > 128 invalid_properties.push('invalid value for "password", the character length must be smaller than or equal to 128.') end if !@username.nil? && @username.to_s.length > 150 invalid_properties.push('invalid value for "username", the character length must be smaller than or equal to 150.') end invalid_properties end |