Remove goog.isNull in source classes

This commit is contained in:
Marc Jansen
2015-09-29 15:20:51 +02:00
parent 30e2f44825
commit e1f477ad8c
18 changed files with 51 additions and 55 deletions
+2 -2
View File
@@ -195,7 +195,7 @@ ol.source.Tile.prototype.getTileGrid = function() {
* @return {ol.tilegrid.TileGrid} Tile grid.
*/
ol.source.Tile.prototype.getTileGridForProjection = function(projection) {
if (goog.isNull(this.tileGrid)) {
if (!this.tileGrid) {
return ol.tilegrid.getForProjection(projection);
} else {
return this.tileGrid;
@@ -231,7 +231,7 @@ ol.source.Tile.prototype.getTileCoordForTileUrlFunction =
var projection = opt_projection !== undefined ?
opt_projection : this.getProjection();
var tileGrid = this.getTileGridForProjection(projection);
goog.asserts.assert(!goog.isNull(tileGrid), 'tile grid needed');
goog.asserts.assert(tileGrid, 'tile grid needed');
if (this.getWrapX() && projection.isGlobal()) {
tileCoord = ol.tilecoord.wrapX(tileCoord, tileGrid, projection);
}