The HttpResponse struct allows to get a reference to the optional error with its error() method, but we can't retrieve its ownership, which could be useful when mapping error reponses in middlewares.
It would be useful to have an additional method to get the ownership of the error.