Adding categories view controller and more error handling