feat: late-bind dmChannelId on FederatedCallEntry when DM created mid-call
When findOrCreateDmChannel creates or finds a local channel for a federatedId that has an active FederatedCallEntry with null dmChannelId, update the entry. Prevents stale null references for Path B calls.
This commit is contained in:
@@ -1690,6 +1690,9 @@ function findOrCreateDmChannel(
|
||||
.run();
|
||||
}
|
||||
}
|
||||
// Late-bind: if a FederatedCallEntry exists for this federatedId with null dmChannelId,
|
||||
// update it now that we have a local channel
|
||||
connectionManager.lateBindFederatedCall(federatedId, existing.id);
|
||||
return existing.id;
|
||||
}
|
||||
|
||||
@@ -1715,6 +1718,10 @@ function findOrCreateDmChannel(
|
||||
.run();
|
||||
}
|
||||
|
||||
// Late-bind: if a FederatedCallEntry exists for this federatedId with null dmChannelId,
|
||||
// update it now that we have a local channel
|
||||
connectionManager.lateBindFederatedCall(federatedId, channelId);
|
||||
|
||||
return channelId;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user