added a error action class to centralize error messaging and handling