Procházet zdrojové kódy

Changed config getter.

Oskar Wrobel před 9 roky
rodič
revize
bfae21e76c

+ 4 - 2
packages/ckeditor5-editor-classic/src/classiceditorui.js

@@ -61,8 +61,10 @@ export default class ClassicEditorUI extends BoxedEditorUI {
 	 * @inheritDoc
 	 */
 	init() {
-		if ( this.editor.config.toolbar ) {
-			this.toolbar.addButtons( this.editor.config.toolbar );
+		const toolbar = this.editor.config.get( 'toolbar' );
+
+		if ( toolbar ) {
+			this.toolbar.addButtons( toolbar );
 		}
 
 		return super.init();