Skip to content

Commit

Permalink
Merge pull request #944 from JeremiahChurch/patch-1
Browse files Browse the repository at this point in the history
fix model_class_name variable in exception raise
  • Loading branch information
jagthedrummer authored Nov 15, 2024
2 parents 577fe8b + c8fda14 commit 16e3e3b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def account_load_and_authorize_resource(model, positional_through = nil, through
# reflect on the belongs_to association of the child model to figure out the class names of the parents.
association = model_class.reflect_on_association(through_as_symbol)
unless association
raise "Your 'account_load_and_authorize_resource' is broken. Tried to reflect on the `#{through_as_symbol}` association of #{model_class_name}, but didn't find one."
raise "Your 'account_load_and_authorize_resource' is broken. Tried to reflect on the `#{through_as_symbol}` association of #{model_class_names}, but didn't find one."
end

association.klass.name
Expand Down

0 comments on commit 16e3e3b

Please sign in to comment.