diff --git a/federationsender/api/perform.go b/federationsender/api/perform.go index 1f717783a..8c30ecbef 100644 --- a/federationsender/api/perform.go +++ b/federationsender/api/perform.go @@ -8,7 +8,10 @@ import ( ) const ( - FederationSenderPerformJoinRequestPath = "/api/federationsender/performJoinRequest" + // FederationSenderPerformJoinRequestPath is the HTTP path for the PerformJoinRequest API. + FederationSenderPerformJoinRequestPath = "/api/federationsender/performJoinRequest" + + // FederationSenderPerformLeaveRequestPath is the HTTP path for the PerformLeaveRequest API. FederationSenderPerformLeaveRequestPath = "/api/federationsender/performLeaveRequest" ) diff --git a/federationsender/query/api.go b/federationsender/query/api.go index 1ef211efc..e33bcc111 100644 --- a/federationsender/query/api.go +++ b/federationsender/query/api.go @@ -1,28 +1,20 @@ package query import ( - "context" "encoding/json" "net/http" "github.com/matrix-org/dendrite/common" "github.com/matrix-org/dendrite/federationsender/api" - "github.com/matrix-org/dendrite/federationsender/types" + "github.com/matrix-org/dendrite/federationsender/storage" rsAPI "github.com/matrix-org/dendrite/roomserver/api" "github.com/matrix-org/util" ) -// FederationSenderQueryDatabase has the APIs needed to implement the query API. -type FederationSenderQueryDatabase interface { - GetJoinedHosts( - ctx context.Context, roomID string, - ) ([]types.JoinedHost, error) -} - // FederationSenderInternalAPI is an implementation of api.FederationSenderInternalAPI type FederationSenderInternalAPI struct { api.FederationSenderInternalAPI - DB FederationSenderQueryDatabase + DB storage.Database RoomserverInputAPI rsAPI.RoomserverInputAPI }