private boolean isFileUnderContentRoot(@Nullable VirtualFile file) {
    return file != null && file.isValid() && myFileIndex.getContentRootForFile(file, false) != null;
  }
private boolean isFileUnderContentRoot(@Nullable VirtualFile file)