mirror of
https://github.com/daffyyyy/CS2-SimpleAdmin.git
synced 2026-03-06 15:26:34 +00:00
Fixed hmtl-incompatible player names
This commit is contained in:
@@ -1,3 +1,4 @@
|
|||||||
|
using System.Web;
|
||||||
using CounterStrikeSharp.API.Core;
|
using CounterStrikeSharp.API.Core;
|
||||||
using CounterStrikeSharp.API.Modules.Admin;
|
using CounterStrikeSharp.API.Modules.Admin;
|
||||||
using CounterStrikeSharp.API.Modules.Menu;
|
using CounterStrikeSharp.API.Modules.Menu;
|
||||||
@@ -33,7 +34,7 @@ namespace CS2_SimpleAdmin.Menus
|
|||||||
IEnumerable<CCSPlayerController> players = Helper.GetValidPlayersWithBots();
|
IEnumerable<CCSPlayerController> players = Helper.GetValidPlayersWithBots();
|
||||||
foreach (CCSPlayerController player in players)
|
foreach (CCSPlayerController player in players)
|
||||||
{
|
{
|
||||||
string optionName = player.PlayerName;
|
string optionName = HttpUtility.HtmlEncode(player.PlayerName);
|
||||||
if (enableFilter != null && enableFilter(player) == false)
|
if (enableFilter != null && enableFilter(player) == false)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user