Skip to content

Commit

Permalink
fix: NPE in location provider (#6960)
Browse files Browse the repository at this point in the history
closes #6959
  • Loading branch information
tpasternak authored Nov 5, 2024
1 parent 8d910d6 commit c7cd1df
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ protected boolean handles(Object element) {
return null;
}
var sourceRoot = index.getSourceRootForFile(file);
if (sourceRoot == null) {
return null;
}
var relativeSourceRoot = WorkspaceRoot.fromProject(project).relativize(sourceRoot);
if (relativeSourceRoot == null) {
return null;
Expand Down

0 comments on commit c7cd1df

Please sign in to comment.