Skip to content

Commit 0dee1a8

Browse files
committed
src/goInstallTools: fix broken gocode-gomod install
?? is misused. It should be || because at some point the extension sets GOBIN to ''. Change-Id: I206e290da9a21abbfb1cc0a90a3fda6dec6a65d6 Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/277293 Trust: Hyang-Ah Hana Kim <[email protected]> Run-TryBot: Hyang-Ah Hana Kim <[email protected]> TryBot-Result: kokoro <[email protected]> Reviewed-by: Rebecca Stambler <[email protected]>
1 parent 1812139 commit 0dee1a8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/goInstallTools.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ export async function installTool(
245245
logVerbose(`install: %s %s\n%s%s`, goBinary, args.join(' '), stdout, stderr);
246246

247247
if (hasModSuffix(tool)) { // Actual installation of the -gomod tool is done by running go build.
248-
const gopath = env['GOBIN'] ?? env['GOPATH'];
248+
const gopath = env['GOBIN'] || env['GOPATH'];
249249
if (!gopath) {
250250
return `GOBIN/GOPATH not configured in environment`;
251251
}

0 commit comments

Comments
 (0)