15e7d8ab2e
1. not list() -> callable() The args of hooking parameters of Sanic have to be callables. For wrong parameters, errors will be generated from: ``` listeners += args ``` By checking just list type, the raised error will be associated with `[args]` instead of `args`, which is not given by users. With this patch, the raised error will be associated with `args`. Then users can notice their argument was neither callable nor list in the easier way. 2. Function -> Functions in document Regarding the parameter as a list is harmless to the user code. But unawareness of its type can be list can limit the potent of the user code. |
||
---|---|---|
.. | ||
__init__.py | ||
__main__.py | ||
blueprints.py | ||
config.py | ||
cookies.py | ||
exceptions.py | ||
log.py | ||
request.py | ||
response.py | ||
router.py | ||
sanic.py | ||
server.py | ||
static.py | ||
utils.py | ||
views.py |