mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-26 20:59:27 +01:00
Factoids: Fix NameErrors in HTTP callback.
This commit is contained in:
parent
4caf35f94b
commit
a4758146d8
@ -129,7 +129,7 @@ class FactoidsCallback(httpserver.SupyHTTPServerCallback):
|
||||
self.write(httpserver.get_template('factoids/index.html'))
|
||||
elif len(parts) == 2:
|
||||
channel = utils.web.urlunquote(parts[0])
|
||||
if not irc.isChannel(channel):
|
||||
if not ircutils.isChannel(channel):
|
||||
self.send_response(404)
|
||||
self.send_header('Content-type', 'text/html; charset=utf-8')
|
||||
self.end_headers()
|
||||
@ -138,8 +138,7 @@ class FactoidsCallback(httpserver.SupyHTTPServerCallback):
|
||||
{'title': 'Factoids - not a channel',
|
||||
'error': 'This is not a channel'})
|
||||
return
|
||||
if not self._plugin.registryValue('web.channel',
|
||||
channel, irc.network):
|
||||
if not self._plugin.registryValue('web.channel', channel):
|
||||
self.send_response(403)
|
||||
self.send_header('Content-type', 'text/html; charset=utf-8')
|
||||
self.end_headers()
|
||||
|
Loading…
Reference in New Issue
Block a user