ソースを参照

darkirc: disallow emtpy PRIVMSG content

dasman 1 年間 前
コミット
2914aff907
1 ファイル変更1 行追加1 行削除
  1. 1 1
      bin/darkirc/src/irc/command.rs

+ 1 - 1
bin/darkirc/src/irc/command.rs

@@ -690,7 +690,7 @@ impl Client {
             ))])
         };
 
-        if !message.starts_with(':') {
+        if !message.starts_with(':') || message.trim() == ":" {
             return Ok(vec![ReplyType::Server((
                 ERR_NOTEXTTOSEND,
                 format!("{} :No text to send", nick),