FLamparski / seeraccept

Track your Ingress portal submissions. This is a MeteorJS application.
4 stars 0 forks source link

App crashes when there are no results for either category #8

Closed FLamparski closed 10 years ago

FLamparski commented 10 years ago

An offshoot of #2, however it's an important case to handle. Count the messages before doing a fetch request!

FLamparski commented 10 years ago

Not tested, but when the fetch fails with a "Nothing to fetch" message, returns an empty array. We'll see how that goes.

FLamparski commented 10 years ago

Callbacks, anyone? The function that calls the callback needs to return after calling it. Because WTF. Otherwise, this happens:

app/server/checkmail.js:33
    f.on('message', function(message, seqno){
      ^
TypeError: Cannot call method 'on' of undefined

Also, something bad happened here. Looks like the callback is not passed in or captured properly -- I probably should pass it in explicitly.

app/server/checkmail.js:73
        if (err) callback(err, null);
                 ^
TypeError: undefined is not a function
FLamparski commented 10 years ago

Fixed in b098038e.