Fixing Redirect to Error Page