added custom error pages
fix namespace warnings for development and production