fixed escaping bug in commands.cpp cogs

This commit is contained in:
Nicholas O'Connor committed 2017-03-27 23:17:00 -07:00
1 parent bfffa2dd7f
commit f140b9b68c
3 files changed
+6 -6

No files matched your search

+2 -2
View File
@@ -29,8 +29,8 @@ DLL_PUBLIC map<string, CommandFunction> cellar::commands::launch_commands() {
desc = " ".join(linesplit[2:]) # Rest of line assumed to be description
cog.outl("cellar::help::set_description(\"{0}\", \"{1}\");"
.format(name, desc
.replace("\"", "\\\"")
.replace("\\", "\\\\")))
.replace("\\", "\\\\")
.replace("\"", "\\\"")))
# the replace methods escape " and \ characters
else:
print("-- No description is available for the {0} command.".format(name))