Skip to content

Commit

Permalink
Fixed issue when installing migrations
Browse files Browse the repository at this point in the history
  • Loading branch information
kobaltz committed Jan 14, 2024
1 parent 5333cf6 commit 170c4d2
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
action_auth (0.2.6)
action_auth (0.2.7)
bcrypt (~> 3.1.0)
rails (~> 7.1)

Expand Down
2 changes: 1 addition & 1 deletion app/models/action_auth/user.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ class User < ApplicationRecord
has_many :action_auth_sessions, dependent: :destroy,
class_name: "ActionAuth::Session", foreign_key: "action_auth_user_id"

if ActionAuth.configuration.webauthn_enabled?
if ActionAuth.configuration&.webauthn_enabled?
has_many :action_auth_webauthn_credentials, dependent: :destroy,
class_name: "ActionAuth::WebauthnCredential", foreign_key: "action_auth_user_id"
end
Expand Down
2 changes: 1 addition & 1 deletion config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
resource :password_reset, only: [:new, :edit, :create, :update]
end

if ActionAuth.configuration.webauthn_enabled?
if ActionAuth.configuration&.webauthn_enabled?
resources :webauthn_credentials, only: [:new, :create, :destroy] do
post :options, on: :collection, as: 'options_for'
end
Expand Down
2 changes: 1 addition & 1 deletion lib/action_auth/version.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module ActionAuth
VERSION = "0.2.6"
VERSION = "0.2.7"
end

0 comments on commit 170c4d2

Please sign in to comment.