Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added clearer error message when doing many to many join without sails #31

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

heyharvs
Copy link

@heyharvs heyharvs commented Nov 2, 2015

When using waterline as a standalone, dominant flag will not fix the error unless the connection is also explicitly set.

@heyharvs heyharvs changed the title added clearer error message when going many to many join when used wi… added clearer error message when doing many to many join without sails Nov 2, 2015
@devinivy
Copy link

devinivy commented Nov 2, 2015

Can you give an example of what you mean by "unless the connection is also explicitly set."? When using waterline standalone, I think a connection always has to be explicitly set on each collection.

@heyharvs
Copy link
Author

heyharvs commented Nov 2, 2015

I was using waterline without sails and only had one connection in the config. Even though I had set the dominant flag on one of the models, the error was telling me it wasn't set. There is no error saying that I needed the connection.. just looking to help make the error more clear for the next person, that's all.

@devinivy
Copy link

devinivy commented Nov 3, 2015

If waterline assigns connections to collections automatically when there's only one connection present, I was not aware of it! I think the fix is to either fail earlier (if waterline does not assign the connection) or allow dominance to work correctly when the connection is not specified explicitly (if waterline does assign the connection). @particlebanana do you know what's expected to work here?

@particlebanana
Copy link
Contributor

@heyharvs can you post a failing example so I can better understand how you are handling connections?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants