Ran
|
Files
9
|
Run time
0s
|
Badge
Embed ▾
README BADGES
|
push
travis-ci
<a href="https://github.com/allenwq/devise-multi_email/commit/<a class=hub.com/allenwq/devise-multi_email/commit/97a522f32c86abba89397b8343e39361485a7cae">97a522f32<a href="https://github.com/allenwq/devise-multi_email/commit/97a522f32c86abba89397b8343e39361485a7cae">">Permit Devise.allow_unconfirmed_access to be nil (#44) Devise currently permits indefinite unconfirmed access when `Devise.allow_unconfirmed_access` is set to `nil`. See: https://github.com/plataformatec/devise/blob/</a><a class="double-link" href="https://github.com/allenwq/devise-multi_email/commit/<a class="double-link" href="https://github.com/allenwq/devise-multi_email/commit/14863ba4c92cd9781a961be0486f0ea7dfe84144">14863ba4c</a>">14863ba4c</a><a href="https://github.com/allenwq/devise-multi_email/commit/97a522f32c86abba89397b8343e39361485a7cae">/lib/generators/templates/devise.rb#L139-L140 However, at present setting this parameter to nil results in NoMethodErrors when evaluating the following: ``` def email=(new_email) multi_email.change_primary_email_to(new_email, allow_unconfirmed: Devise.allow_unconfirmed_access_for > 0.days) end ``` This commit creates a new method that checks to ensure if the Devise configuration permits any period in which an unconfirmed may log in and uses it to determine whether or not an unconfirmed email address may be added to a user.
265 of 278 relevant lines covered (95.32%)
25.14 hits per line
Coverage | ∆ | File | Lines | Relevant | Covered | Missed | Hits/Line |
---|