We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 068241a commit 9d14980Copy full SHA for 9d14980
packages/core/src/shared/vscode/env.ts
@@ -67,9 +67,9 @@ export { extensionVersion }
67
*
68
* @param throwWhen Throw if minimum vscode is equal or later than this version.
69
*/
70
-export function isMinVscode(options: { throwWhen: string }): boolean {
+export function isMinVscode(options?: { throwWhen: string }): boolean {
71
const minVscode = getMinVscodeVersion()
72
- if (options.throwWhen && semver.gte(minVscode, options.throwWhen)) {
+ if (options?.throwWhen && semver.gte(minVscode, options.throwWhen)) {
73
throw Error(`Min vscode ${minVscode} >= ${options.throwWhen}. Delete or update the code that called this.`)
74
}
75
return vscode.version.startsWith(getMinVscodeVersion())
0 commit comments