fix error page which were causing errors