Skip to content

Commit 58852c4

Browse files
Nazar65sivaschenko
authored andcommitted
Remove duplicated event
1 parent 1492fca commit 58852c4

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

lib/internal/Magento/Framework/Data/Form/Element/Editor.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -309,11 +309,11 @@ protected function _getPluginButtonsHtml($visible = true)
309309
$configStyle = '';
310310
if (isset($buttonOptions['style'])) {
311311
$configStyle = $buttonOptions['style'];
312-
}
312+
}
313313
// phpcs:disable Magento2.Performance.ForeachArrayMerge
314314
$buttonOptions = array_merge($buttonOptions, ['style' => 'display:none;' . $configStyle]);
315-
// phpcs:enable
316-
}
315+
// phpcs:enable
316+
}
317317
$buttonsHtml .= $this->_getButtonHtml($buttonOptions);
318318
}
319319
}
@@ -411,7 +411,7 @@ protected function _getButtonHtml($data)
411411
protected function _wrapIntoContainer($html)
412412
{
413413
if (!$this->getConfig('use_container')) {
414-
return '<div class="admin__control-wysiwig">' .$html . '</div>';
414+
return '<div class="admin__control-wysiwig">' . $html . '</div>';
415415
}
416416

417417
$html = '<div id="editor' . $this->getHtmlId() . '"'

lib/web/mage/adminhtml/wysiwyg/tiny_mce/tinymce4Adapter.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@ define([
118118
tinyMCE4.init(settings);
119119
this.getPluginButtons().hide();
120120
varienGlobalEvents.clearEventHandlers('open_browser_callback');
121+
this.eventBus.clearEventHandlers('open_browser_callback');
121122
this.eventBus.attachEventHandler('open_browser_callback', tinyMceEditors.get(self.id).openFileBrowser);
122123
}.bind(this));
123124
},

0 commit comments

Comments
 (0)