Use es6 version of methods

This commit is contained in:
Matt Bierner
2020-03-02 11:59:52 -08:00
parent b23926ba6f
commit 0fa3af8b60
4 changed files with 6 additions and 9 deletions

View File

@@ -8,7 +8,6 @@ import { onUnexpectedError } from 'vs/base/common/errors';
import { Disposable, DisposableStore, IDisposable } from 'vs/base/common/lifecycle';
import { Schemas } from 'vs/base/common/network';
import { isWeb } from 'vs/base/common/platform';
import { startsWith } from 'vs/base/common/strings';
import { URI, UriComponents } from 'vs/base/common/uri';
import * as modes from 'vs/editor/common/modes';
import { localize } from 'vs/nls';
@@ -74,7 +73,7 @@ class WebviewViewTypeTransformer {
}
public toExternal(viewType: string): string | undefined {
return startsWith(viewType, this.prefix)
return viewType.startsWith(this.prefix)
? viewType.substr(this.prefix.length)
: undefined;
}