Browse Source

Fixed escapes for unparsed parameters

tags/1.0-rc
RogueException 9 years ago
parent
commit
0eb869211c
1 changed files with 2 additions and 3 deletions
  1. +2
    -3
      src/Discord.Net.Commands/CommandParser.cs

+ 2
- 3
src/Discord.Net.Commands/CommandParser.cs View File

@@ -12,8 +12,7 @@ namespace Discord.Commands
Parameter,
QuotedParameter
}

//TODO: Check support for escaping
public static async Task<ParseResult> ParseArgs(Command command, IMessage context, string input, int startPos)
{
CommandParameter curParam = null;
@@ -43,7 +42,7 @@ namespace Discord.Commands
}
}
//Are we escaping the next character?
if (c == '\\')
if (c == '\\' && (curParam == null || !curParam.IsUnparsed))
{
isEscaping = true;
continue;


Loading…
Cancel
Save