Skip to content

Commit

Permalink
_updateLogo onAdd
Browse files Browse the repository at this point in the history
  • Loading branch information
Molly Lloyd authored and jfirebaugh committed Jul 7, 2017
1 parent 1939a52 commit 8818af3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/ui/control/logo_control.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ class LogoControl {
this._container.style.display = 'none';

this._map.on('sourcedata', this._updateLogo);
this._updateLogo();
return this._container;
}

Expand All @@ -41,7 +42,7 @@ class LogoControl {
}

_updateLogo(e) {
if (e && e.sourceDataType === 'metadata') {
if (!e || e.sourceDataType === 'metadata') {
this._container.style.display = this._logoRequired() ? 'block' : 'none';
}
}
Expand Down

0 comments on commit 8818af3

Please sign in to comment.