Update Hangfire Dashboard Authorization syntax

Updated the `Authorization` property in `app.UseHangfireDashboard`
to use modern C# collection initialization syntax (square brackets)
instead of the older array initialization syntax (curly braces).
This change ensures consistency with modern C# conventions.
This commit is contained in:
2026-07-13 13:23:07 +02:00
parent 4af0ed7d14
commit 511fb159c4

View File

@@ -140,7 +140,7 @@ app.UseAuthorization();
// Add Hangfire Dashboard with no authentication (for development) // Add Hangfire Dashboard with no authentication (for development)
app.UseHangfireDashboard("/hangfire", new DashboardOptions app.UseHangfireDashboard("/hangfire", new DashboardOptions
{ {
Authorization = new[] { new AllowAllDashboardAuthorizationFilter() } Authorization = [new AllowAllDashboardAuthorizationFilter()]
}); });
// Add Health Check UI route (accessible outside Hangfire dashboard) // Add Health Check UI route (accessible outside Hangfire dashboard)