Skip to content

Commit 7b735a0

Browse files
committed
Avoid using last token if not using token auth
1 parent d5fe980 commit 7b735a0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/kotlin/com/coder/gateway/views/steps/CoderWorkspacesStepView.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -451,7 +451,7 @@ class CoderWorkspacesStepView : CoderWizardStep<CoderWorkspacesStepSelection>(
451451
settings.defaultURL()
452452
}
453453
val token =
454-
if (!lastUrl.isNullOrBlank() && !lastToken.isNullOrBlank()) {
454+
if (settings.requireTokenAuth && !lastUrl.isNullOrBlank() && !lastToken.isNullOrBlank()) {
455455
lastToken to Source.LAST_USED
456456
} else if (url != null) {
457457
settings.token(url.first)

0 commit comments

Comments
 (0)