0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-12-27 07:54:05 +01: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 &)
{