Ver código fonte

Docs: Fixed error's code and added more info about it. [skip ci]

Piotrek Koszuliński 7 anos atrás
pai
commit
f348d0e2b8
1 arquivos alterados com 7 adições e 2 exclusões
  1. 7 2
      packages/ckeditor5-engine/src/model/nodelist.js

+ 7 - 2
packages/ckeditor5-engine/src/model/nodelist.js

@@ -154,9 +154,14 @@ export default class NodeList {
 			/**
 			 * Given offset cannot be found in the node list.
 			 *
-			 * @error nodelist-offset-out-of-bounds
+			 * @error model-nodelist-offset-out-of-bounds
+			 * @param {Number} offset
+			 * @param {module:engine/model/nodelist~NodeList} nodeList Stringified node list.
 			 */
-			throw new CKEditorError( 'model-nodelist-offset-out-of-bounds: Given offset cannot be found in the node list.' );
+			throw new CKEditorError( 'model-nodelist-offset-out-of-bounds: Given offset cannot be found in the node list.', {
+				offset,
+				nodeList: this
+			} );
 		}
 
 		return this.length;