Explorar o código

Changed: MarkerCollection#getMarkersGroup - indexOf -> startsWith.

Szymon Cofalik %!s(int64=9) %!d(string=hai) anos
pai
achega
23d2916361
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      packages/ckeditor5-engine/src/model/markercollection.js

+ 1 - 1
packages/ckeditor5-engine/src/model/markercollection.js

@@ -143,7 +143,7 @@ export default class MarkerCollection {
 	 */
 	*getMarkersGroup( prefix ) {
 		for ( let marker of this._markers.values() ) {
-			if ( marker.name.indexOf( prefix + ':' ) === 0 ) {
+			if ( marker.name.startsWith( prefix + ':' ) ) {
 				yield marker;
 			}
 		}