[usages] look for usages of files even if their names start with .

This commit is contained in:
Alexander Zolotov
2018-04-06 20:55:02 +03:00
parent e675a053f2
commit 4c97e3c035
@@ -32,7 +32,8 @@ public class CachesBasedRefSearcher extends QueryExecutorBase<PsiReference, Refe
if (refElement instanceof PsiFileSystemItem && !(refElement instanceof SyntheticFileSystemItem)) {
final VirtualFile vFile = ((PsiFileSystemItem)refElement).getVirtualFile();
if (vFile != null) {
text = vFile.getNameWithoutExtension();
String fileNameWithoutExtension = vFile.getNameWithoutExtension();
text = fileNameWithoutExtension.isEmpty() ? vFile.getName() : fileNameWithoutExtension;
}
// We must not look for file references with the file language's case-sensitivity,
// since case-sensitivity of the references themselves depends either on file system