mirror of
https://github.com/matrix-org/dendrite.git
synced 2026-01-16 10:33:11 -06:00
Provide EventProvider to gmsl.PerformJoin directly
This commit is contained in:
parent
a246690d5f
commit
6e8666870d
|
|
@ -159,7 +159,7 @@ func (r *FederationInternalAPI) performJoinUsingServer(
|
||||||
PrivateKey: r.cfg.Matrix.PrivateKey,
|
PrivateKey: r.cfg.Matrix.PrivateKey,
|
||||||
KeyID: r.cfg.Matrix.KeyID,
|
KeyID: r.cfg.Matrix.KeyID,
|
||||||
KeyRing: r.keyRing,
|
KeyRing: r.keyRing,
|
||||||
EventProvider: federatedEventProvider,
|
EventProvider: federatedEventProvider(ctx, r.federation, r.keyRing, user.Domain(), serverName),
|
||||||
}
|
}
|
||||||
callbacks := fclient.PerformJoinCallbacks{
|
callbacks := fclient.PerformJoinCallbacks{
|
||||||
FederationFailure: func(server spec.ServerName) {
|
FederationFailure: func(server spec.ServerName) {
|
||||||
|
|
@ -191,6 +191,7 @@ func (r *FederationInternalAPI) performJoinUsingServer(
|
||||||
return fmt.Errorf("UpdatedRoom: failed to update room with joined hosts: %s", err)
|
return fmt.Errorf("UpdatedRoom: failed to update room with joined hosts: %s", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO: Can I change this to not take respState but instead just take an opaque list of events?
|
||||||
if err = roomserverAPI.SendEventWithState(
|
if err = roomserverAPI.SendEventWithState(
|
||||||
context.Background(),
|
context.Background(),
|
||||||
r.rsAPI,
|
r.rsAPI,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue