From 4ad2fdf25f35dbed47f7e065cf5122014fd13dc1 Mon Sep 17 00:00:00 2001 From: Chomp Date: Mon, 3 Feb 2025 13:31:28 +0000 Subject: [PATCH 1/2] Removed unused variable --- .../Commando/SptCommands/ProfileCommand/ProfileSptCommand.cs | 4 ---- 1 file changed, 4 deletions(-) diff --git a/Libraries/Core/Helpers/Dialogue/Commando/SptCommands/ProfileCommand/ProfileSptCommand.cs b/Libraries/Core/Helpers/Dialogue/Commando/SptCommands/ProfileCommand/ProfileSptCommand.cs index 26695954..210b77f1 100644 --- a/Libraries/Core/Helpers/Dialogue/Commando/SptCommands/ProfileCommand/ProfileSptCommand.cs +++ b/Libraries/Core/Helpers/Dialogue/Commando/SptCommands/ProfileCommand/ProfileSptCommand.cs @@ -26,16 +26,12 @@ public class ProfileSptCommand( * spt profile level 20 * spt profile skill metabolism 10 */ - // TODO: Fix this shit as Valens doesn't know Regex. protected Regex _commandRegex = new( @"^spt profile (?level|skill)((?<=.*skill) (?[\w]+))? (?(?!0+)[0-9]+)$" ); protected Regex _examineRegex = new(@"^spt profile (?examine)"); - // - protected SavedCommand _savedCommand = null; - public string GetCommand() { return "profile"; From fcae006a138362d47d6ebac4a16471e24adfd72d Mon Sep 17 00:00:00 2001 From: Chomp Date: Mon, 3 Feb 2025 14:11:01 +0000 Subject: [PATCH 2/2] Improved `GenerateHashForData` error logging --- Libraries/Core/Utils/HashUtil.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Libraries/Core/Utils/HashUtil.cs b/Libraries/Core/Utils/HashUtil.cs index 771e089a..bf377c45 100644 --- a/Libraries/Core/Utils/HashUtil.cs +++ b/Libraries/Core/Utils/HashUtil.cs @@ -1,4 +1,4 @@ -using System.Text; +using System.Text; using System.Text.RegularExpressions; using System.Security.Cryptography; using SptCommon.Annotations; @@ -92,7 +92,7 @@ public class HashUtil return Convert.ToHexString(sha1HashData).Replace("-", string.Empty); } - throw new NotImplementedException("Provided hash algorithm is not supported."); + throw new NotImplementedException($"Provided hash algorithm: {algorithm} is not supported."); } ///