derbyjs / racer

Realtime model synchronization engine for Node.js
1.19k stars 118 forks source link

Errors from query execution are silently swallowed #68

Closed SLaks closed 11 years ago

SLaks commented 11 years ago

If a query provider returns an error, the error is swallowed silently and an empty result set is returned.

The problem stems from Store._fetchAndCompileQueryData, which accepts a callback with only one parameter.
The parameter is supposed to indicate whether the result is a single item. If the query returns an error, the error is also passed to this parameter.

This method is called by Store.middleware(), but I'm not sure how to report errors through the middleware chain.

nateps commented 11 years ago

No longer relevant in 0.5