Skip to content

Commit

Permalink
fix: clear custom controls list as first step on setCustomControls
Browse files Browse the repository at this point in the history
  • Loading branch information
paodb authored and javier-godoy committed Sep 26, 2024
1 parent 7891f74 commit a57dda6
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -787,6 +787,7 @@ public void addCustomControls(CustomControl... customControls) {
* @param customControls list of custom controls to add to the map
*/
public void setCustomControls(CustomControl... customControls) {
this.customControls.clear();
this.getElement().executeJs("this._removeCustomControls()").then((e) -> {
JsonArray jsonArray = Json.createArray();
for (int i = 0; i < customControls.length; i++) {
Expand Down

0 comments on commit a57dda6

Please sign in to comment.