Fixed attributions disappearing, closed #405
This commit is contained in:
parent
0ef3058512
commit
2ebbfdf40c
@ -28,7 +28,10 @@ L.Control.Attribution = L.Class.extend({
|
|||||||
if (!text) {
|
if (!text) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
this._attributions[text] = true;
|
if (!this._attributions[text]) {
|
||||||
|
this._attributions[text] = 0;
|
||||||
|
}
|
||||||
|
this._attributions[text]++;
|
||||||
this._update();
|
this._update();
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -36,7 +39,7 @@ L.Control.Attribution = L.Class.extend({
|
|||||||
if (!text) {
|
if (!text) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
delete this._attributions[text];
|
this._attributions[text]--;
|
||||||
this._update();
|
this._update();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user