mirror of
https://github.com/hoernschen/dendrite.git
synced 2025-07-31 13:22:46 +00:00
Use SenderID Type (#3105)
This commit is contained in:
parent
7a1fd7f512
commit
8ea1a11105
60 changed files with 502 additions and 275 deletions
|
@ -14,7 +14,11 @@
|
|||
|
||||
package api
|
||||
|
||||
import "regexp"
|
||||
import (
|
||||
"regexp"
|
||||
|
||||
"github.com/matrix-org/gomatrixserverlib/spec"
|
||||
)
|
||||
|
||||
// SetRoomAliasRequest is a request to SetRoomAlias
|
||||
type SetRoomAliasRequest struct {
|
||||
|
@ -62,7 +66,7 @@ type GetAliasesForRoomIDResponse struct {
|
|||
// RemoveRoomAliasRequest is a request to RemoveRoomAlias
|
||||
type RemoveRoomAliasRequest struct {
|
||||
// ID of the user removing the alias
|
||||
SenderID string `json:"user_id"`
|
||||
SenderID spec.SenderID `json:"user_id"`
|
||||
// The room alias to remove
|
||||
Alias string `json:"alias"`
|
||||
}
|
||||
|
|
|
@ -77,8 +77,8 @@ type InputRoomEventsAPI interface {
|
|||
}
|
||||
|
||||
type QuerySenderIDAPI interface {
|
||||
QuerySenderIDForUser(ctx context.Context, roomID string, userID spec.UserID) (string, error)
|
||||
QueryUserIDForSender(ctx context.Context, roomID string, senderID string) (*spec.UserID, error)
|
||||
QuerySenderIDForUser(ctx context.Context, roomID string, userID spec.UserID) (spec.SenderID, error)
|
||||
QueryUserIDForSender(ctx context.Context, roomID string, senderID spec.SenderID) (*spec.UserID, error)
|
||||
}
|
||||
|
||||
// Query the latest events and state for a room from the room server.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue