Skip to content

Commit

Permalink
Merge pull request #5017 from camptocamp/fix_bg_slider
Browse files Browse the repository at this point in the history
Fix val type in getSetBgLayerOpacity function
  • Loading branch information
fredj committed Jul 15, 2019
2 parents 3c76243 + 5d44ef2 commit f72a0f9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions contribs/gmf/src/backgroundlayerselector/component.js
Original file line number Diff line number Diff line change
Expand Up @@ -206,14 +206,14 @@ Controller.prototype.handleThemesChange_ = function() {

/**
* Getter/setter for background layer overlay, used by opacity slider.
* @param {?number} val The opacity.
* @param {number|undefined} val The opacity.
* @return {number} The background layer opacity.
*/
Controller.prototype.getSetBgLayerOpacity = function(val) {
if (!this.opacityLayer) {
throw new Error('Missing opacityLayer');
}
if (val !== null) {
if (val !== undefined) {
this.opacityLayer.setOpacity(val);
}
return this.opacityLayer.getOpacity();
Expand Down

0 comments on commit f72a0f9

Please sign in to comment.