add error page and remove some warning