File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -77,6 +77,12 @@ export class DocumentContentProvider implements vscode.TextDocumentContentProvid
7777 }
7878 let uri : vscode . Uri ;
7979 if ( wFolderUri && ( wFolderUri . scheme === FILESYSTEM_SCHEMA || wFolderUri . scheme === FILESYSTEM_READONLY_SCHEMA ) ) {
80+ // Avoid later adding a namespace=XXX queryparam when this is implied by the authority part of the workspace folder uri
81+ // otherwise stopping at a breakpoint would load a second copy of the file
82+ const authorityParts = wFolderUri . authority . split ( ":" ) ;
83+ if ( authorityParts . length === 2 && namespace ?. toLowerCase ( ) === authorityParts [ 1 ] ) {
84+ namespace = "" ;
85+ }
8086 const flat = new URLSearchParams ( wFolderUri . query ) . get ( "flat" ) == "1" ;
8187 const fileExt = name . split ( "." ) . pop ( ) ;
8288 const fileName = name
@@ -180,6 +186,9 @@ export class DocumentContentProvider implements vscode.TextDocumentContentProvid
180186 uri = uri . with ( {
181187 query : "csp=1" ,
182188 } ) ;
189+ } else {
190+ // Remove filters etc which the folder uri may have specified
191+ uri = uri . with ( { query : "" } ) ;
183192 }
184193 }
185194 return uri ;
You can’t perform that action at this time.
0 commit comments