]> git.cworth.org Git - turbot/blobdiff - turbot/interaction.py
Make /solved reject a missing solution string
[turbot] / turbot / interaction.py
index bb0a8db7947b1b0eafb515317230a901504099b8..76eb061d024a29475bc01a368ab67abd3b3e162f 100644 (file)
@@ -536,6 +536,10 @@ def solved(turb, body, args):
     if not puzzle:
         return bot_reply("Sorry, this is not a puzzle channel.")
 
+    if not args:
+        return bot_reply(
+            "Error, no solution provided. Usage: `/solved SOLUTION HERE`")
+
     # Set the status and solution fields in the database
     puzzle['status'] = 'solved'
     puzzle['solution'].append(args)