Fix SegmentMetadataQuery when queryGranularity is requested but not present. (#3181)

This commit is contained in:
Gian Merlino 2016-06-23 14:30:50 -07:00 committed by Fangjin Yang
parent 2696b0c451
commit a437fb150b
1 changed files with 1 additions and 1 deletions

View File

@ -132,7 +132,7 @@ public class SegmentMetadataQueryRunnerFactory implements QueryRunnerFactory<Seg
if (metadata == null) { if (metadata == null) {
metadata = segment.asStorageAdapter().getMetadata(); metadata = segment.asStorageAdapter().getMetadata();
} }
queryGranularity = metadata.getQueryGranularity(); queryGranularity = metadata != null ? metadata.getQueryGranularity() : null;
} else { } else {
queryGranularity = null; queryGranularity = null;
} }