Skip to content

Commit

Permalink
Fix: Prompt for credentials when a network share access is denied (#1…
Browse files Browse the repository at this point in the history
  • Loading branch information
nmangue authored Mar 5, 2024
1 parent 2460818 commit a83507e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Files.App/Utils/Global/NetworkDrivesAPI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ public static async Task<bool> AuthenticateNetworkShare(string path)

Win32Error connectionError = WNetAddConnection3(HWND.NULL, nr, null, null, 0); // if creds are saved, this will return NO_ERROR

if (connectionError == Win32Error.ERROR_LOGON_FAILURE)
if (connectionError == Win32Error.ERROR_LOGON_FAILURE || connectionError == Win32Error.ERROR_ACCESS_DENIED)
{
var dialog = DynamicDialogFactory.GetFor_CredentialEntryDialog(path);
await dialog.ShowAsync();
Expand Down

0 comments on commit a83507e

Please sign in to comment.