Selaa lähdekoodia

Smaller threshold for `fastDiff()`.

Krzysztof Krztoń 6 vuotta sitten
vanhempi
commit
2ff5209444
1 muutettua tiedostoa jossa 1 lisäystä ja 1 poistoa
  1. 1 1
      packages/ckeditor5-utils/src/diff.js

+ 1 - 1
packages/ckeditor5-utils/src/diff.js

@@ -33,7 +33,7 @@ export default function diff( a, b, cmp ) {
 	const bLength = b.length;
 
 	// Perform `fastDiff` for longer strings/arrays (see #269).
-	if ( Math.min( aLength, bLength ) >= 400 && aLength + bLength >= 1300 || aLength + bLength >= 2000 ) {
+	if ( aLength > 200 || bLength > 200 || aLength + bLength > 300 ) {
 		return diff.fastDiff( a, b, cmp, true );
 	}