return err when err != nil
MODIFY
src/github.com/matrix-org/dendrite/roomserver/query/query.go
src/github.com/matrix-org/dendrite/roomserver/query/query.go
@@ -271,7 +271,7 @@ func (r *RoomserverQueryAPI) QueryMembershipsForRoom(
membershipEventNID, stillInRoom, err := r.DB.GetMembership(ctx, roomNID, request.Sender)
if err != nil {
- return nil
+ return err
}
if membershipEventNID == 0 {

return err when err != nil (#545)