Skip to content
This repository has been archived by the owner on Dec 5, 2019. It is now read-only.

run time errors -- how to handle? #3

Open
dominictarr opened this issue Apr 19, 2013 · 0 comments
Open

run time errors -- how to handle? #3

dominictarr opened this issue Apr 19, 2013 · 0 comments

Comments

@dominictarr
Copy link
Owner

so, using map-reduce again after a while,
got this error. think the key wasn't an array or a string.

what is the best way to handle this error? as a db you might not want it to throw...
probably better that your query does nothing for a bit...

/Users/dominictarr/c/node_modules/map-reduce/index.js:27
            array.push(id)
                  ^
TypeError: Object #<Object> has no method 'push'
    at module.exports.mapper.get.db.get.async (/Users/dominictarr/c/node_modules/map-reduce/index.js:27:19)
    at /Users/dominictarr/c/npmd/db.js:77:3
    at module.exports.acc (/Users/dominictarr/c/node_modules/map-reduce/index.js:23:19)
    at LevelUP.get (/Users/dominictarr/c/npmd/node_modules/levelup/lib/levelup.js:189:13)

I think I'm gonna make it default to [] but leave this issue open incase some one else has ideas.

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

No branches or pull requests

1 participant