Skip to content

Commit

Permalink
Fix regex replace (#24525)
Browse files Browse the repository at this point in the history
  • Loading branch information
Charles-Gagnon authored Sep 28, 2023
1 parent c5e8ecd commit 696cdc3
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ export class AzCliTool extends ToolBase {

protected getVersionFromOutput(output: string): SemVer | undefined {
if (output && output.includes('azure-cli')) {
return new SemVer(output.split(EOL)[0].replace('azure-cli', '').replace(/ /g, '').replace('*', ''));
return new SemVer(output.split(EOL)[0].replace(/azure-cli/g, '').replace(/ /g, '').replace(/\*/g, ''));
} else {
return undefined;
}
Expand Down

0 comments on commit 696cdc3

Please sign in to comment.