added error messages in global view and did some cleanup