Skip to content

Commit

Permalink
[preprocessor/folder] fix project path collide if substring matches
Browse files Browse the repository at this point in the history
  • Loading branch information
williamchong committed Jun 17, 2024
1 parent d230f99 commit 31e71b1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion preprocessor/folder/folder.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ func findProjectWithFilePath(filePath string, projects []*ProjectQueryResult) *P
syncRoot := config.GetConfig().FolderPreprocessor.SyncFolderRoot
for _, project := range projects {
projectPath := project.ProjectPath
projectPath = filepath.Join(syncRoot, projectPath)
projectPath = filepath.Join(syncRoot, projectPath) + "/"
if strings.HasPrefix(filePath, projectPath) {
return project
}
Expand Down

0 comments on commit 31e71b1

Please sign in to comment.