A small fix for capturing 500 errors and missing HTML