Using null instead of null or object or undefined

This commit is contained in:
Tim Schaub
2012-09-28 12:06:34 +02:00
parent 3e34013c09
commit eb29e6a43c
3 changed files with 10 additions and 20 deletions

View File

@@ -282,14 +282,10 @@ ol.Map.prototype.getContainer = function() {
/**
* @param {ol.Pixel} pixel Pixel.
* @return {ol.Coordinate|undefined} Coordinate.
* @return {ol.Coordinate} Coordinate.
*/
ol.Map.prototype.getCoordinateFromPixel = function(pixel) {
if (this.isDef()) {
return this.renderer_.getCoordinateFromPixel(pixel);
} else {
return undefined;
}
return this.isDef() ? this.renderer_.getCoordinateFromPixel(pixel) : null;
};