X Tutup
Skip to content

Commit b6ee208

Browse files
committed
fix(benchmarks): remove reference to String.prototype.contains()
https://github.com/tc39/tc39-notes/blob/master/es6/2014-11/nov-18.md#51--44-arrayprototypecontains-and-stringprototypecontains removed String.prototype.contains() from standard, and is not implemented in most runtimes (SpiderMonkey still being an exception). Closes #3570
1 parent b5fb05b commit b6ee208

File tree

1 file changed

+2
-2
lines changed
  • modules/benchmarks/src/naive_infinite_scroll

1 file changed

+2
-2
lines changed

modules/benchmarks/src/naive_infinite_scroll/common.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import {Math} from 'angular2/src/facade/math';
2-
2+
import {StringWrapper} from 'angular2/src/facade/lang';
33
import {ListWrapper, Map, MapWrapper} from 'angular2/src/facade/collection';
44

55
export var ITEMS = 1000;
@@ -86,7 +86,7 @@ export class RawEntity {
8686
}
8787

8888
remove(key: string) {
89-
if (!key.contains('.')) {
89+
if (!StringWrapper.contains(key, '.')) {
9090
return MapWrapper.delete(this._data, key);
9191
}
9292
var pieces = key.split('.');

0 commit comments

Comments
 (0)
X Tutup