diff --git a/rowbot b/rowbot index 8a0b8d1..5dc341a 100755 --- a/rowbot +++ b/rowbot @@ -660,6 +660,18 @@ who() { # app hooks ## +hook_pre_PRIVMSG_nolog() { + local words + read -ra words <<< "${args[@]:(-1)}" + + if [[ ${words[0]} = "[nolog]" || ${words[0]} = nolog: ]]; then + info "this message was redacted" + return 1 + else + return 0 + fi +} + hook_pre_PRIVMSG_CTCP() { if [[ ${args[1]} != $'\x01'*$'\x01' ]]; then return 0