allow throw errors inside callbacks