Skip to content

Commit

Permalink
fix(core): don't report plugin usage if no plugins loaded
Browse files Browse the repository at this point in the history
  • Loading branch information
tchiotludo committed Feb 8, 2022
1 parent 06896b8 commit a7ae312
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ public static List<PluginUsage> of(ApplicationContext applicationContext) {
KestraApplicationContext context = (KestraApplicationContext) applicationContext;
PluginRegistry pluginRegistry = context.getPluginRegistry();

if (pluginRegistry == null) {
return List.of();
}

return pluginRegistry.getPlugins()
.stream()
.map(registeredPlugin -> PluginUsage.builder()
Expand Down

0 comments on commit a7ae312

Please sign in to comment.