Refactor collection initializers to use C# 12 collection expressions
This commit updates various files across the Core and WebApp projects to replace traditional collection initializers with C# 12 collection expressions. Changes include modifications to EventAssignment.cs, TeamScheduler_DecisionTree.cs, CareerField.cs, EventDefinition.cs, and several components in the WebApp. These updates enhance code readability and maintainability by adhering to modern C# syntax standards.
This commit is contained in:
@@ -18,7 +18,7 @@ public class TeamScheduler_DecisionTree
|
||||
{
|
||||
var timeSlots = new IList<Team>[_timeSlotCount];
|
||||
for (var i = 0; i < _timeSlotCount; i++)
|
||||
timeSlots[i] = new List<Team>();
|
||||
timeSlots[i] = [];
|
||||
|
||||
foreach (var team in _teams.OrderByDescending(t => t.Students.Count))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user