Skip to content

Commit 80920c6

Browse files
SeeminglyScienceTylerLeonhardt
authored andcommitted
Fix exception when remoting from Windows to non-Windows (#760)
Checking for DSC capability is currently done by attempting to import a drive qualified path to where we would expect the DSC module. This fails during parameter validation due to an invalid drive. This change broadens the scope of the catch block to account for this exception.
1 parent 73206f1 commit 80920c6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/PowerShellEditorServices/Session/Capabilities/DscBreakpointCapability.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ public static DscBreakpointCapability CheckForCapability(
104104
{
105105
moduleInfo = powerShell.Invoke().FirstOrDefault();
106106
}
107-
catch (CmdletInvocationException e)
107+
catch (RuntimeException e)
108108
{
109109
logger.WriteException("Could not load the DSC module!", e);
110110
}

0 commit comments

Comments
 (0)