diff options
Diffstat (limited to 'irc')
-rw-r--r-- | irc/command.rkt | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/irc/command.rkt b/irc/command.rkt index 30f9830..6aa4b04 100644 --- a/irc/command.rkt +++ b/irc/command.rkt @@ -73,3 +73,16 @@ (reply (~s cr)))) (reply "There is no such command"))) (reply "You need to supply a command name, e.g. (help list)"))) + +(define-command (ignore-add nick) + #:power 2 + (hash-set! (network-storage "ignore") nick #t) + (persist-network "ignore")) + +(define-command (ignore-del nick) + #:power 2 + (hash-remove! (network-storage "ignore") nick) + (persist-network "ignore")) + +(define (ignored? nick) + (hash-has-key? (network-storage "ignore") nick)) |