Created
September 6, 2011 15:00
-
-
Save mergulhao/1197783 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# FIX for this issue | |
# https://github.com/thoughtbot/shoulda-matchers/commit/6b4035c11783a0588e78d3705bb9425b9b5f45b8 | |
Shoulda::Matchers::ActiveRecord::AssociationMatcher.class_eval do | |
protected | |
def foreign_key | |
reflection.respond_to?(:foreign_key) ? reflection.foreign_key : reflection.primary_key_name | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment