removed some of the boilerplate stuff from dons other project
fixed error page to print error