From b8d549505503f1c99ece474e2cec81632ee15887 Mon Sep 17 00:00:00 2001 From: RaidMax Date: Sat, 30 May 2020 14:14:42 -0500 Subject: [PATCH] include client name in stats info result --- Plugins/Stats/Dtos/StatsInfoResult.cs | 5 +++++ Plugins/Stats/Helpers/StatsResourceQueryHelper.cs | 1 + 2 files changed, 6 insertions(+) diff --git a/Plugins/Stats/Dtos/StatsInfoResult.cs b/Plugins/Stats/Dtos/StatsInfoResult.cs index 183bbb4fa..628419f17 100644 --- a/Plugins/Stats/Dtos/StatsInfoResult.cs +++ b/Plugins/Stats/Dtos/StatsInfoResult.cs @@ -5,6 +5,11 @@ namespace Stats.Dtos { public class StatsInfoResult { + /// + /// client name + /// + public string Name { get; set; } + /// /// ranking on the server /// diff --git a/Plugins/Stats/Helpers/StatsResourceQueryHelper.cs b/Plugins/Stats/Helpers/StatsResourceQueryHelper.cs index 61ec3a0e9..dc76ce293 100644 --- a/Plugins/Stats/Helpers/StatsResourceQueryHelper.cs +++ b/Plugins/Stats/Helpers/StatsResourceQueryHelper.cs @@ -44,6 +44,7 @@ namespace Stats.Helpers .Where(_stats => _stats.ClientId == query.ClientId) .Select(_stats => new StatsInfoResult { + Name = _stats.Client.CurrentAlias.Name, ServerId = _stats.ServerId, Kills = _stats.Kills, Deaths = _stats.Deaths,