0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-09-28 19:58:53 +02:00

modules/client/profile: Wrap and rethrow remote http error in m::error here.

This commit is contained in:
Jason Volk 2019-08-16 00:38:30 -07:00
parent ec96b6564b
commit dc47cc7a93

View file

@ -270,9 +270,16 @@ try
{
std::rethrow_exception(eptr);
}
catch(const http::error &)
catch(const http::error &e)
{
throw;
throw m::error
{
e.code, "M_UNKNOWN",
"Server '%s' responded to profile request for %s with :%s",
user.user_id.host(),
string_view{user.user_id},
e.content
};
}
catch(const ctx::timeout &)
{