Can't throw exceptions from within callbacks! Use the node.js pattern of
passing an exception object to the callback instead.