Skip to content

Commit

Permalink
Merge pull request #35463 from geoand/#35443
Browse files Browse the repository at this point in the history
Fix potential NPE in MicrometerRecorder
  • Loading branch information
geoand authored Aug 22, 2023
2 parents 211d239 + a8b1641 commit 88de658
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,8 @@ public void configureRegistries(MicrometerConfig config,
Class<?> registryClass = registry.getClass();
applyMeterFilters(registry, classMeterFilters.get(registryClass));

var classSpecificCustomizers = classMeterRegistryCustomizers.get(registryClass);
var classSpecificCustomizers = classMeterRegistryCustomizers.getOrDefault(registryClass,
Collections.emptyList());
var newList = new ArrayList<MeterRegistryCustomizer>(
globalMeterRegistryCustomizers.size() + classSpecificCustomizers.size());
newList.addAll(globalMeterRegistryCustomizers);
Expand Down

0 comments on commit 88de658

Please sign in to comment.