File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -52,7 +52,9 @@ const convertToProotPath = (url = "") => {
5252 if ( isAcodeTerminalPublicSafUri ( url ) ) {
5353 try {
5454 const { docId } = Uri . parse ( url ) ;
55- const cleanDocId = decodeURIComponent ( docId || "" ) ;
55+ const cleanDocId = / : : / . test ( url )
56+ ? decodeURIComponent ( docId || "" )
57+ : docId || "" ;
5658 if ( ! cleanDocId ) return "/public" ;
5759 if ( cleanDocId . startsWith ( publicDir ) ) {
5860 return cleanDocId . replace ( publicDir , "/public" ) || "/public" ;
@@ -64,7 +66,9 @@ const convertToProotPath = (url = "") => {
6466 const relativePath = cleanDocId . slice ( "public:" . length ) ;
6567 return relativePath ? Path . join ( "/public" , relativePath ) : "/public" ;
6668 }
67- const relativePath = cleanDocId . replace ( / ^ \/ + / , "" ) ;
69+ const relativePath = cleanDocId
70+ . replace ( / ^ \/ + / , "" )
71+ . replace ( / ^ p u b l i c \/ / , "" ) ;
6872 return relativePath ? Path . join ( "/public" , relativePath ) : "/public" ;
6973 } catch ( error ) {
7074 console . warn (
You can’t perform that action at this time.
0 commit comments