Properly bubble getInfowindow errors up to response

This commit is contained in:
Sandro Santilli 2012-08-14 20:01:05 +02:00
parent b30c8d9a98
commit 9ba80acab7

View File

@ -77,8 +77,8 @@ module.exports = function(){
that.req2params(req, this);
},
function(err, data){
if (err) throw err;
cartoData.getInfowindow(data, callback);
if (err) callback(err, null);
else cartoData.getInfowindow(data, callback);
}
);
};