-
Notifications
You must be signed in to change notification settings - Fork 140
Fixed build_join_dependency to handle Squeel's join nodes. #79
base: master
Are you sure you want to change the base?
Conversation
I don't see any tests for this fix -- how are you managing to push a Squeel join node through to build_join_dependency? Can you show a use case that fails without this patch? |
Well I'm not sure how I managed to push the Squeel join, this happen in a relatively complex bit of code. My controller send a scope (some are made using Squeel, others are more simple) dynamically to the model, but that seems to happens only when the relation is already scoped with a specific scope:
This is then passed to meta_search and it complains about I'll see if I can narrow it down. |
Sorry, I still hadn't had the time to look further into this but while moving to Rails 3.2 I've checked that the bug is still there and here's the stacktrace, maybe it could be useful:
|
Strangely enough, Squeel doesn't appear anywhere in the stacktrace. I really don't get it! |
This happens to me when I use squeel in the join of a scope. This doesn't work: But this does: |
This fix a compatibility issue with Squeel.