Don't set args to a split of the data left over when parsing out a command if

there's not a space after the command
This commit is contained in:
jesopo 2018-11-04 17:23:34 +00:00
parent 1610cfb499
commit c1e9825a33

View file

@ -92,9 +92,12 @@ def parse_line(line: str) -> IRCLine:
if line[0] == ":":
prefix_str, line = line[1:].split(" ", 1)
prefix = seperate_hostmask(prefix_str)
command, _, line = line.partition(" ")
args = line.split(" ")
args = []
command, sep, line = line.partition(" ")
if sep:
args = line.split(" ")
if arbitrary:
args.append(arbitrary)