Skip to content

Commit

Permalink
Fix synced breakpoints for untitled files
Browse files Browse the repository at this point in the history
  • Loading branch information
SeeminglyScience committed Sep 13, 2023
1 parent bed8cc3 commit 347f500
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -694,7 +694,9 @@ private static SyncedBreakpoint CreateFromServerBreakpoint(Breakpoint serverBrea
if (clientBreakpoint.Location is not null)
{
kind = SyncedBreakpointKind.Line;
script = clientBreakpoint.Location.Uri.GetFileSystemPath();
script = clientBreakpoint.Location.Uri.Scheme is "untitled"
? clientBreakpoint.Location.Uri.ToString()
: clientBreakpoint.Location.Uri.GetFileSystemPath();
line = clientBreakpoint.Location.Range.Start.Line + 1;
column = clientBreakpoint.Location.Range.Start.Character is int c and not 0 ? c : 0;
}
Expand Down

0 comments on commit 347f500

Please sign in to comment.