Prevent `captured` from leaking onto global

If only we had linting on - this stuff would have never happened :). Next on the TODO list.