diff --git a/modules/apps/frontend-editor/frontend-editor-alloyeditor-web/src/main/resources/META-INF/resources/js/alloyeditor_source.js b/modules/apps/frontend-editor/frontend-editor-alloyeditor-web/src/main/resources/META-INF/resources/js/alloyeditor_source.js index 47c8987157527e..9464f9981e393f 100644 --- a/modules/apps/frontend-editor/frontend-editor-alloyeditor-web/src/main/resources/META-INF/resources/js/alloyeditor_source.js +++ b/modules/apps/frontend-editor/frontend-editor-alloyeditor-web/src/main/resources/META-INF/resources/js/alloyeditor_source.js @@ -87,11 +87,14 @@ AUI.add( _getEditorStateLexiconIcon() { var instance = this; - var currentState = MAP_TOGGLE_STATE[instance._isVisible]; + var icon; - var icon = currentState.icon; + var currentState = MAP_TOGGLE_STATE[instance._isVisible]; - if (!icon) { + if (currentState.icon) { + icon = currentState.icon.cloneNode(true); + } + else { icon = Liferay.Util.getLexiconIcon( currentState.iconCssClass );