From a07fc0ef352ecc4ef21247cbbc6abaf536b31df3 Mon Sep 17 00:00:00 2001 From: Neil Alexander Date: Tue, 2 Jun 2020 09:34:36 +0100 Subject: [PATCH] Return correct error to LookupRoomAlias --- clientapi/routing/directory.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clientapi/routing/directory.go b/clientapi/routing/directory.go index b1dfb56fb..3d4b5f5bc 100644 --- a/clientapi/routing/directory.go +++ b/clientapi/routing/directory.go @@ -77,7 +77,7 @@ func DirectoryRoom( if fedErr != nil { // TODO: Return 502 if the remote server errored. // TODO: Return 504 if the remote server timed out. - util.GetLogger(req.Context()).WithError(err).Error("federation.LookupRoomAlias failed") + util.GetLogger(req.Context()).WithError(fedErr).Error("federation.LookupRoomAlias failed") return jsonerror.InternalServerError() } res.RoomID = fedRes.RoomID