Closed morokhovets closed 11 years ago
When trying something like
geddy.model.Model.first params.id, {includes: ['assoc']}, (err, model) => model.assocs.length #=> ALWAYS 1 (or 0 if empty)
you'll always will get association array with only 1 element. Model.first always adds "LIMIT 1" to query contradicting with eager-loading logic.
Fixed in 31feb96b578682a60f135d03ec4ab507d4cc8aff, pushed to NPM in v0.2.2.
When trying something like
you'll always will get association array with only 1 element. Model.first always adds "LIMIT 1" to query contradicting with eager-loading logic.