action_auth 0.2.15 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0e857cd3b20f2efab695368d0b8b127a63cfe1639ef44dc4d346399c8aa446f7
4
- data.tar.gz: 791837aee1c820e999896082cbdec807b65a0df7db1d29de02b31774682c5448
3
+ metadata.gz: fa8d3dbc8281ff24b428e82568470f21268c085d94352302c4f5bf4134041526
4
+ data.tar.gz: e266314b2359d22db1983ae7a9a13ddda8fd589819c834ccb5fb5e28418176a6
5
5
  SHA512:
6
- metadata.gz: f881d2e71ec6d1f2f1a5ccc764a9eecb333671163cba5ae8958e4a0b36c408f9670d05e818ce4ff1ab244583f2738f4376f9e8e987cc418748c8fce3217ee4ce
7
- data.tar.gz: 30773441bd4c9184638cedba7ee4bb8a635f72a761bf6cc6abee5da65c26a4bdbe3cbd4aa72d7774a514276db539818e1b9f89b860c5a790b6a6785a898297d0
6
+ metadata.gz: dd44e5d7bc676a69f0b7d60196a68b02c77ea9c7c042faa3251acce7b937e6a13fa7f8e44d4c982dc1d45a28d6e29124d7489f06649bd97296278964c409d12e
7
+ data.tar.gz: 288208466865e199fd803d5dc57fcb537467c166084be4812261083742de66d3314a86b287f612e261bfba7ed4ebd4c35ddcfd7199ad99de9aac8ea04937dbf1
@@ -5,13 +5,13 @@ module ActionAuth
5
5
 
6
6
  def show
7
7
  @user.update! verified: true
8
- redirect_to main_app.root_path, notice: "Thank you for verifying your email address"
8
+ redirect_to sign_in_path, notice: "Thank you for verifying your email address"
9
9
  end
10
10
 
11
11
  def create
12
12
  user = ActionAuth::User.find_by(email: params[:email])
13
13
  UserMailer.with(user: user).email_verification.deliver_later if user
14
- redirect_to main_app.root_path, notice: "We sent a verification email to your email address"
14
+ redirect_to sign_in_path, notice: "We sent a verification email to your email address"
15
15
  end
16
16
 
17
17
  private
@@ -27,9 +27,9 @@ module ActionAuth
27
27
  def redirect_to_root
28
28
  if @user.email_previously_changed?
29
29
  resend_email_verification
30
- redirect_to main_app.root_path, notice: "Your email has been changed"
30
+ redirect_to sign_in_path, notice: "Your email has been changed. Check your email to verify your email."
31
31
  else
32
- redirect_to main_app.root_path
32
+ redirect_to sign_in_path
33
33
  end
34
34
  end
35
35
 
@@ -14,7 +14,7 @@ module ActionAuth
14
14
  send_password_reset_email
15
15
  redirect_to sign_in_path, notice: "Check your email for reset instructions"
16
16
  else
17
- redirect_to new_identity_password_reset_path, alert: "You can't reset your password until you verify your email"
17
+ redirect_to sign_in_path, alert: "You can't reset your password until you verify your email"
18
18
  end
19
19
  end
20
20
 
@@ -7,7 +7,7 @@ module ActionAuth
7
7
 
8
8
  def update
9
9
  if @user.update(user_params)
10
- redirect_to main_app.root_path, notice: "Your password has been changed"
10
+ redirect_to sign_in_path, notice: "Your password has been changed"
11
11
  else
12
12
  render :edit, status: :unprocessable_entity
13
13
  end
@@ -10,12 +10,12 @@ module ActionAuth
10
10
  if @user.save
11
11
  if ActionAuth.configuration.verify_email_on_sign_in
12
12
  send_email_verification
13
- redirect_to main_app.root_path, notice: "Welcome! You have signed up successfully. Please check your email to verify your account."
13
+ redirect_to sign_in_path, notice: "Welcome! You have signed up successfully. Please check your email to verify your account."
14
14
  else
15
15
  session_record = @user.action_auth_sessions.create!
16
16
  cookies.signed.permanent[:session_token] = { value: session_record.id, httponly: true }
17
17
 
18
- redirect_to main_app.root_path, notice: "Welcome! You have signed up successfully"
18
+ redirect_to sign_in_path, notice: "Welcome! You have signed up successfully"
19
19
  end
20
20
  else
21
21
  render :new, status: :unprocessable_entity
@@ -1,3 +1,3 @@
1
1
  module ActionAuth
2
- VERSION = "0.2.15"
2
+ VERSION = "0.3.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: action_auth
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.15
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dave Kimura
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-02-01 00:00:00.000000000 Z
11
+ date: 2024-02-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -120,7 +120,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
120
120
  - !ruby/object:Gem::Version
121
121
  version: '0'
122
122
  requirements: []
123
- rubygems_version: 3.5.5
123
+ rubygems_version: 3.5.6
124
124
  signing_key:
125
125
  specification_version: 4
126
126
  summary: A simple Rails engine for authorization.