Use toString() instead of + ''

This commit is contained in:
Tom Payne
2014-01-02 22:14:02 +01:00
parent 94c22055be
commit 46267a9059
2 changed files with 4 additions and 4 deletions

View File

@@ -540,7 +540,7 @@ ol.structs.RBush.prototype.getExtent = function(opt_extent) {
*/
ol.structs.RBush.prototype.getKey_ = function(value) {
goog.asserts.assert(goog.isObject(value));
return goog.getUid(value) + '';
return goog.getUid(value).toString();
};

View File

@@ -37,9 +37,9 @@ ol.TileUrlFunction.createFromTemplate = function(template) {
if (goog.isNull(tileCoord)) {
return undefined;
} else {
return template.replace('{z}', '' + tileCoord.z)
.replace('{x}', '' + tileCoord.x)
.replace('{y}', '' + tileCoord.y);
return template.replace('{z}', tileCoord.z.toString())
.replace('{x}', tileCoord.x.toString())
.replace('{y}', tileCoord.y.toString());
}
});
};