Created
February 24, 2014 16:08
-
-
Save killercup/9191206 to your computer and use it in GitHub Desktop.
Replacing brackets with CoffeeScript
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
Post | |
.findOne _id: id, 'public': true, 'accepted': true | |
.populate path: '_team', select: 'name' | |
.populate path: '_user', select: 'name' | |
.populate path: 'comments._user', select: 'name _team' | |
.populate path: 'likes._user', select: 'name _team' | |
.exec() |
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
Post | |
.findOne({_id: id, 'public': true, 'accepted': true}) | |
.populate({path: '_team', select: 'name'}) | |
.populate({path: '_user', select: 'name'}) | |
.populate({path: 'comments._user', select: 'name _team'}) | |
.populate({path: 'likes._user', select: 'name _team'}) | |
.exec() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment