diff --git a/BankingBot/BankingBot.csproj b/BankingBot/BankingBot.csproj index abff66c..908f6ea 100644 --- a/BankingBot/BankingBot.csproj +++ b/BankingBot/BankingBot.csproj @@ -21,6 +21,7 @@ DEBUG;TRACE prompt 4 + false pdbonly @@ -29,6 +30,7 @@ TRACE prompt 4 + false @@ -62,6 +64,7 @@ + diff --git a/BankingBot/Extensions/StringExtensions.cs b/BankingBot/Extensions/StringExtensions.cs new file mode 100644 index 0000000..a32b0c5 --- /dev/null +++ b/BankingBot/Extensions/StringExtensions.cs @@ -0,0 +1,13 @@ +using System; +using System.Text.RegularExpressions; + +namespace BankingBot.Extensions +{ + public static class StringExtensions + { + public static int AsInteger(this string str) + { + return int.Parse(Regex.Replace(str, @"[^\d]", "")); + } + } +}