Replace IRCException by IMException, as nemubot is not only built for IRC
This commit is contained in:
parent
ac33ceb579
commit
8b4f08c5bd
40 changed files with 183 additions and 188 deletions
|
|
@ -6,7 +6,7 @@ from urllib.parse import quote
|
|||
import re
|
||||
|
||||
from nemubot import context
|
||||
from nemubot.exception import IRCException
|
||||
from nemubot.exception import IMException
|
||||
from nemubot.hooks import hook
|
||||
from nemubot.tools import web
|
||||
|
||||
|
|
@ -100,12 +100,12 @@ class WFAResults:
|
|||
})
|
||||
def calculate(msg):
|
||||
if not len(msg.args):
|
||||
raise IRCException("Indicate a calcul to compute")
|
||||
raise IMException("Indicate a calcul to compute")
|
||||
|
||||
s = WFAResults(' '.join(msg.args))
|
||||
|
||||
if not s.success:
|
||||
raise IRCException(s.error)
|
||||
raise IMException(s.error)
|
||||
|
||||
res = Response(channel=msg.channel, nomore="No more results")
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue