diff --git a/src/shared/GitHub/GitHubAuthentication.cs b/src/shared/GitHub/GitHubAuthentication.cs index 6c2f9fd52..f63a48d1a 100644 --- a/src/shared/GitHub/GitHubAuthentication.cs +++ b/src/shared/GitHub/GitHubAuthentication.cs @@ -79,7 +79,7 @@ public async Task GetAuthenticationAsync(Uri targetU throw new ArgumentException(@$"Must specify at least one {nameof(AuthenticationModes)}", nameof(modes)); } - if (TryFindHelperExecutablePath(out string helperPath)) + if (Context.SessionManager.IsDesktopSession && TryFindHelperExecutablePath(out string helperPath)) { var promptArgs = new StringBuilder("prompt"); if (modes == AuthenticationModes.All) @@ -207,7 +207,7 @@ public async Task GetTwoFactorCodeAsync(Uri targetUri, bool isSms) { ThrowIfUserInteractionDisabled(); - if (TryFindHelperExecutablePath(out string helperPath)) + if (Context.SessionManager.IsDesktopSession && TryFindHelperExecutablePath(out string helperPath)) { var args = new StringBuilder("2fa"); if (isSms) args.Append(" --sms");