Callback to exit from 404 queries