hopefully fix sorting

This commit is contained in:
Pilzinsel64
2025-06-13 10:42:56 +02:00
parent 1da2e2183c
commit be61994ae7

View File

@@ -185,7 +185,7 @@ public class ApiServer : IApiServer
public virtual Dictionary<string, string[]> GetEndpoints()
{
return handlers.GroupBy(n => n.Attribute.Route).OrderBy(n => n.Key).ToDictionary(n => n.Key, n => n.SelectMany(n => n.Attribute.Methods.OrderBy(n => n)).ToArray());
return handlers.OrderBy(n => n.Attribute.Route).GroupBy(n => n.Attribute.Route).ToDictionary(n => n.Key, n => n.SelectMany(n => n.Attribute.Methods.OrderBy(n => n)).ToArray());
}
public virtual void RegisterHandler<T>(T instance) where T : class