Change map variables from undefined to null for consistency
This commit is contained in:
+4
-4
@@ -249,14 +249,14 @@ class Overlay extends BaseObject {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the map associated with this overlay.
|
* Get the map associated with this overlay.
|
||||||
* @return {import("./PluggableMap.js").default|undefined} The map that the
|
* @return {import("./PluggableMap.js").default|null} The map that the
|
||||||
* overlay is part of.
|
* overlay is part of.
|
||||||
* @observable
|
* @observable
|
||||||
* @api
|
* @api
|
||||||
*/
|
*/
|
||||||
getMap() {
|
getMap() {
|
||||||
return /** @type {import("./PluggableMap.js").default|undefined} */ (
|
return /** @type {import("./PluggableMap.js").default|null} */ (
|
||||||
this.get(Property.MAP)
|
this.get(Property.MAP) || null
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -378,7 +378,7 @@ class Overlay extends BaseObject {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the map to be associated with this overlay.
|
* Set the map to be associated with this overlay.
|
||||||
* @param {import("./PluggableMap.js").default|undefined|null} map The map that the
|
* @param {import("./PluggableMap.js").default|null} map The map that the
|
||||||
* overlay is part of. Pass `null` to just remove the overlay from the current map.
|
* overlay is part of. Pass `null` to just remove the overlay from the current map.
|
||||||
* @observable
|
* @observable
|
||||||
* @api
|
* @api
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ class Control extends BaseObject {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @private
|
* @private
|
||||||
* @type {import("../PluggableMap.js").default|undefined|null}
|
* @type {import("../PluggableMap.js").default|null}
|
||||||
*/
|
*/
|
||||||
this.map_ = null;
|
this.map_ = null;
|
||||||
|
|
||||||
@@ -98,7 +98,7 @@ class Control extends BaseObject {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the map associated with this control.
|
* Get the map associated with this control.
|
||||||
* @return {import("../PluggableMap.js").default|undefined|null} Map.
|
* @return {import("../PluggableMap.js").default|null} Map.
|
||||||
* @api
|
* @api
|
||||||
*/
|
*/
|
||||||
getMap() {
|
getMap() {
|
||||||
@@ -110,7 +110,7 @@ class Control extends BaseObject {
|
|||||||
* Pass `null` to just remove the control from the current map.
|
* Pass `null` to just remove the control from the current map.
|
||||||
* Subclasses may set up event handlers to get notified about changes to
|
* Subclasses may set up event handlers to get notified about changes to
|
||||||
* the map here.
|
* the map here.
|
||||||
* @param {import("../PluggableMap.js").default|null} [map] Map.
|
* @param {import("../PluggableMap.js").default|null} map Map.
|
||||||
* @api
|
* @api
|
||||||
*/
|
*/
|
||||||
setMap(map) {
|
setMap(map) {
|
||||||
|
|||||||
Reference in New Issue
Block a user