add grid tests and return error with invalid grid

This commit is contained in:
Konstantin Käfer
2011-05-13 15:51:52 -04:00
parent e02b1a84bd
commit 14d969e810
52 changed files with 88 additions and 15 deletions
+2 -2
View File
@@ -243,8 +243,8 @@ MBTiles.prototype.grid = function(x, y, z, callback) {
return memo;
}, {});
callback(null, _(JSON.parse(grid)).extend({ data: data }));
} catch(err) {
callback(err);
} catch (err) {
callback('Grid is invalid');
}
}
);