a little more consistent error handing in the client