File tree Expand file tree Collapse file tree 2 files changed +4
-7
lines changed
Expand file tree Collapse file tree 2 files changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -117,10 +117,7 @@ export class DistributionManager implements DistributionProvider {
117117
118118 public async getCodeQlPathWithoutVersionCheck ( ) : Promise < string | undefined > {
119119 const distribution = await this . getDistributionWithoutVersionCheck ( ) ;
120- if ( distribution === undefined ) {
121- return undefined ;
122- }
123- return distribution . codeQlPath ;
120+ return distribution ?. codeQlPath ;
124121 }
125122
126123 /**
@@ -184,7 +181,7 @@ export class DistributionManager implements DistributionProvider {
184181 minSecondsSinceLastUpdateCheck : number ) : Promise < DistributionUpdateCheckResult > {
185182 const distribution = await this . getDistributionWithoutVersionCheck ( ) ;
186183 const extensionManagedCodeQlPath = await this . _extensionSpecificDistributionManager . getCodeQlPathWithoutVersionCheck ( ) ;
187- if ( distribution !== undefined && distribution . codeQlPath !== extensionManagedCodeQlPath ) {
184+ if ( distribution ? .codeQlPath !== extensionManagedCodeQlPath ) {
188185 // A distribution is present but it isn't managed by the extension.
189186 return createInvalidLocationResult ( ) ;
190187 }
Original file line number Diff line number Diff line change @@ -202,8 +202,8 @@ export async function activate(ctx: ExtensionContext): Promise<void> {
202202 case DistributionKind . CustomPathConfig :
203203 return `Please update the \"CodeQL CLI Executable Path\" setting to point to a CLI in the version range ${ codeQlVersionRange } .` ;
204204 case DistributionKind . PathEnvironmentVariable :
205- return `Please update the CodeQL CLI on your PATH to a version in the range ${ codeQlVersionRange } , or ` +
206- `set the \"CodeQL CLI Executable Path\" setting to the path of a CLI in the version range ${ codeQlVersionRange } .` ;
205+ return `Please update the CodeQL CLI on your PATH to a version compatible with ${ codeQlVersionRange } , or ` +
206+ `set the \"CodeQL CLI Executable Path\" setting to the path of a CLI version compatible with ${ codeQlVersionRange } .` ;
207207 }
208208 } ) ( ) ;
209209
You can’t perform that action at this time.
0 commit comments