Change the way we handle status codes and raise errors