Преглед на файлове

Internal: Made the error initialization catch statements more informative.

Marek Lewandowski преди 6 години
родител
ревизия
252db15af1

+ 4 - 4
packages/ckeditor5-build-balloon-block/README.md

@@ -39,8 +39,8 @@ And use it in your website:
 		.then( editor => {
 			window.editor = editor;
 		} )
-		.catch( err => {
-			console.error( err.stack );
+		.catch( error => {
+			console.error( 'There was a problem with initializing the editor', error );
 		} );
 </script>
 ```
@@ -58,8 +58,8 @@ BalloonEditor
 	.then( editor => {
 		window.editor = editor;
 	} )
-	.catch( err => {
-		console.error( err.stack );
+	.catch( error => {
+		console.error( 'There was a problem with initializing the editor', error );
 	} );
 ```
 

+ 2 - 2
packages/ckeditor5-build-balloon-block/sample/index.html

@@ -32,8 +32,8 @@
 		.then( editor => {
 			window.editor = editor;
 		} )
-		.catch( err => {
-			console.error( err.stack );
+		.catch( error => {
+			console.error( 'There was a problem with initializing the editor', error );
 		} );
 </script>
 

+ 2 - 2
packages/ckeditor5-build-balloon-block/tests/manual/ckeditor-cjs-version.js

@@ -12,6 +12,6 @@ BalloonEditor.create( document.querySelector( '#editor' ) )
 	.then( editor => {
 		window.editor = editor;
 	} )
-	.catch( err => {
-		console.error( err.stack );
+	.catch( error => {
+		console.error( 'There was a problem with initializing the editor', error );
 	} );

+ 2 - 2
packages/ckeditor5-build-balloon-block/tests/manual/ckeditor.js

@@ -11,6 +11,6 @@ BalloonEditor.create( document.querySelector( '#editor' ) )
 	.then( editor => {
 		window.editor = editor;
 	} )
-	.catch( err => {
-		console.error( err.stack );
+	.catch( error => {
+		console.error( 'There was a problem with initializing the editor', error );
 	} );