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

Update model.js #34

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

Update model.js #34

wants to merge 1 commit into from

Conversation

vitaly-t
Copy link

@vitaly-t vitaly-t commented Mar 2, 2016

your example was broken in so many places...
I tried to fix it, following the logic I saw there, but the last one cannot even be fixed, its a contradiction - you return nothing from the query, and trying to process the result...

your example  was broken in so many places...
i fixed, following the logic I saw there, but the last one cannot even be fixed, its a contradiction - you return nothing from the query, and trying to process the result...
@vitaly-t
Copy link
Author

vitaly-t commented Mar 2, 2016

Also, returning things like:

return users.length ? users[0] : false;

is generally a bad idea.

@vitaly-t
Copy link
Author

vitaly-t commented Mar 2, 2016

Missed one thing, the last:

yield pg.none

should also become

yield db.none

@ruimarinho
Copy link
Member

Thanks for the PR! I'll take a look at it during the weekend.

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

Successfully merging this pull request may close these issues.

2 participants