Skip to content

Commit

Permalink
fix null reference check
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastianburckhardt committed Jan 12, 2022
1 parent 15147f4 commit 88e6ef2
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ ScaleStatus GetScaleStatusCore(int workerCount, NetheriteScaleMetrics[] metrics)
ScaleRecommendation recommendation;
try
{
if (metrics.Length == 0)
if (metrics == null || metrics.Length == 0)
{
recommendation = new ScaleRecommendation(ScaleAction.None, keepWorkersAlive: true, reason: "missing metrics");
}
Expand Down

0 comments on commit 88e6ef2

Please sign in to comment.