Skip to content

Commit ec531f9

Browse files
committed
do not attempt to get history cache for directories
fixes #4288
1 parent f31fdd2 commit ec531f9

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

opengrok-indexer/src/main/java/org/opengrok/indexer/history/FileHistoryCache.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -655,6 +655,10 @@ private void createDirectoriesForFiles(Set<String> files, Repository repository,
655655
@Override
656656
public History get(File file, Repository repository, boolean withFiles) throws CacheException {
657657

658+
if (file.isDirectory()) {
659+
return null;
660+
}
661+
658662
if (isUpToDate(file)) {
659663
File cacheFile = getCachedFile(file);
660664
try {

0 commit comments

Comments
 (0)