revise_auth-jets 0.2.8 → 0.2.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/revise_auth/email_controller.rb +1 -1
- data/lib/revise_auth/model.rb +1 -2
- data/lib/revise_auth/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e48e02003acd849df39aeaff4dd064bea52e22fc73934a26187dcfd101e5b757
|
4
|
+
data.tar.gz: 323f662581f6c06ab48955979394dc46a6e854a51e327a11097448f74ef66e92
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 923e6b3260121421e3d9c0db4fe693ed5aa85e03dadfe4d0ba8602bdf3956211331159caea7b73e099ec6db4b5950fad6612f1c161abee7c6607cda152a73538
|
7
|
+
data.tar.gz: bc6c0e639d25510b33500622a35165316a6e1e51646d31535a6ab445227b903aa05cc74eda4fd94502247cb5d3a6480afd8bb9e39996f34d0486afc625ddad3a
|
@@ -3,7 +3,7 @@ class ReviseAuth::EmailController < ReviseAuthController
|
|
3
3
|
|
4
4
|
# GET /profile/email?confirmation_token=abcdef
|
5
5
|
def show
|
6
|
-
if User.
|
6
|
+
if User.find_by(confirmation_token: params[:confirmation_token])&.confirm_email_change
|
7
7
|
#flash[:notice] = I18n.t("revise_auth.email_confirmed")
|
8
8
|
redirect_to(user_signed_in? ? profile_path : root_path)
|
9
9
|
else
|
data/lib/revise_auth/model.rb
CHANGED
@@ -26,9 +26,8 @@ module ReviseAuth
|
|
26
26
|
|
27
27
|
# Generates a confirmation token and send email to the user
|
28
28
|
def send_confirmation_instructions
|
29
|
-
token = generate_token_for
|
30
29
|
# = breaks the query params
|
31
|
-
token.gsub("=", '')
|
30
|
+
token = generate_token_for.gsub("=", '')
|
32
31
|
self.confirmation_token = token
|
33
32
|
self.save!
|
34
33
|
ReviseAuth::Mailer.with(user: self.unconfirmed_email, token: token).confirm_email.deliver_later
|
data/lib/revise_auth/version.rb
CHANGED