Skip to content

Commit

Permalink
Wrap that User in a string (thoughtbot#813)
Browse files Browse the repository at this point in the history
DEPRECATION WARNING: Passing a class to the  is deprecated and will raise an ArgumentError in Rails 5.2. It eagerloads more classes than necessary and potentially creates circular dependencies. Please pass the class name as a string:  (called from <class:Invitation> at /Users/BenAMorgan/Sites/administrate/spec/generators/dashboard_generator_spec.rb:273)
  • Loading branch information
BenMorganIO authored and iarie committed Jun 17, 2017
1 parent 4142316 commit 924612b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion spec/generators/dashboard_generator_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ class Comment < ActiveRecord::Base
end
class User < ActiveRecord::Base; end
class Invitation < ActiveRecord::Base
belongs_to :sender, class_name: User
belongs_to :sender, class_name: "User"
belongs_to :recipient, class_name: "User"
end

Expand Down

0 comments on commit 924612b

Please sign in to comment.