Page MenuHomePhabricator

D13792.id45449.diff
No OneTemporary

D13792.id45449.diff

diff --git a/lib/tunnelbroker/peer-to-peer-message-handler.js b/lib/tunnelbroker/peer-to-peer-message-handler.js
--- a/lib/tunnelbroker/peer-to-peer-message-handler.js
+++ b/lib/tunnelbroker/peer-to-peer-message-handler.js
@@ -32,7 +32,7 @@
function PeerToPeerMessageHandler(props: Props): React.Node {
const { socketSend, getSessionCounter, doesSocketExist } = props;
- const { addListener, removeListener } = useTunnelbroker();
+ const { addListener, removeListener, socketState } = useTunnelbroker();
const peerToPeerMessageHandler = usePeerToPeerMessageHandler();
const handleOlmMessageToDevice = useHandleOlmMessageToDevice();
const persistedStateLoaded = usePersistedStateLoaded();
@@ -104,7 +104,10 @@
socketSend,
],
);
- const { enqueue } = useActionsQueue(processItem, persistedStateLoaded);
+ const { enqueue } = useActionsQueue(
+ processItem,
+ persistedStateLoaded && !!socketState.isAuthorized,
+ );
const tunnelbrokerMessageListener = React.useCallback(
async (message: TunnelbrokerToDeviceMessage) => {

File Metadata

Mime Type
text/plain
Expires
Fri, Nov 22, 2:45 PM (18 h, 37 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2561850
Default Alt Text
D13792.id45449.diff (1 KB)

Event Timeline