mirror of
https://github.com/RaidMax/IW4M-Admin.git
synced 2025-06-10 15:20:48 -05:00
add cancellation token for rcon connection to allow more granular control
This commit is contained in:
@ -1190,7 +1190,7 @@ namespace SharedLibraryCore.Commands
|
||||
|
||||
public static async Task<string> GetNextMap(Server s, ITranslationLookup lookup)
|
||||
{
|
||||
var mapRotation = (await s.GetDvarAsync<string>("sv_mapRotation")).Value?.ToLower() ?? "";
|
||||
var mapRotation = (await s.GetDvarAsync<string>("sv_mapRotation", token: s.Manager.CancellationToken)).Value?.ToLower() ?? "";
|
||||
var regexMatches = Regex.Matches(mapRotation,
|
||||
@"((?:gametype|exec) +(?:([a-z]{1,4})(?:.cfg)?))? *map ([a-z|_|\d]+)", RegexOptions.IgnoreCase)
|
||||
.ToList();
|
||||
|
Reference in New Issue
Block a user