def add(self, name, func):
        was_empty = self._empty()
        self.hooks.setdefault(name, []).append(func)
        if self.app and was_empty and not self._empty(): self.app.reset()
Attach a callback to a hook.
dataset/ETHPy150Open adampresley/bottlepy-bootstrap/app/bottle.py/HooksPlugin.add