Skip to content

Commit

Permalink
Use tableize instead of downcase to support CamelCaseModel (#157)
Browse files Browse the repository at this point in the history
  • Loading branch information
henrikbjorn committed Aug 13, 2023
1 parent e9caad8 commit 6dddc11
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/mailers/passwordless/mailer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ def magic_link(session, token = nil)
@session = session
@token = token || session.token

@magic_link = send(:"#{session.authenticatable_type.downcase.pluralize}_token_sign_in_url", token)
@magic_link = send(:"#{session.authenticatable_type.tableize}_token_sign_in_url", token)

email_field = @session.authenticatable.class.passwordless_email_field
mail(
Expand Down

0 comments on commit 6dddc11

Please sign in to comment.