File tree Expand file tree Collapse file tree
sources/SilkTouch/SilkTouch/Mods Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -200,7 +200,7 @@ await proj.GetCompilationAsync(ct)
200200 var typeNamesLongestFirst = typeNames . OrderByDescending ( x => x . Key . Length ) . ToArray ( ) ;
201201
202202 var documentPaths = proj
203- . Documents . Select ( d => d . FilePath )
203+ . Documents . Select ( d => d . RelativePath ( ) )
204204 . Where ( d => d != null )
205205 . ToHashSet ( ) ;
206206
@@ -223,12 +223,13 @@ await proj.GetCompilationAsync(ct)
223223
224224 // Rename doc and update path
225225 var originalName = doc . Name ;
226- var originalPath = doc . FilePath ;
226+ var originalPath = doc . RelativePath ( ) ;
227227 doc = doc . ReplaceNameAndPath ( oldName , newName ) ;
228+ var newPath = doc . RelativePath ( ) ;
228229
229230 // Check for path conflict
230231 documentPaths . Remove ( originalPath ) ;
231- if ( ! documentPaths . Add ( doc . FilePath ! ) )
232+ if ( ! documentPaths . Add ( newPath ) )
232233 {
233234 logger . LogError (
234235 $ "{ originalName } -> { doc . Name } failed to rename file as a file already exists at { doc . FilePath } "
You can’t perform that action at this time.
0 commit comments