Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3104014
D13802.id45448.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D13802.id45448.diff
View Options
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
@@ -9,6 +9,7 @@
} from './use-peer-to-peer-message-handler.js';
import { useLoggedInUserInfo } from '../hooks/account-hooks.js';
import { useActionsQueue } from '../hooks/actions-queue.js';
+import { usePersistedStateLoaded } from '../selectors/app-state-selectors.js';
import type { InboundP2PMessage } from '../types/sqlite-types.js';
import type { MessageReceiveConfirmation } from '../types/tunnelbroker/message-receive-confirmation-types.js';
import {
@@ -34,6 +35,7 @@
const { addListener, removeListener } = useTunnelbroker();
const peerToPeerMessageHandler = usePeerToPeerMessageHandler();
const handleOlmMessageToDevice = useHandleOlmMessageToDevice();
+ const persistedStateLoaded = usePersistedStateLoaded();
const processItem = React.useCallback(
async (
@@ -102,7 +104,7 @@
socketSend,
],
);
- const { enqueue } = useActionsQueue(processItem);
+ const { enqueue } = useActionsQueue(processItem, persistedStateLoaded);
const tunnelbrokerMessageListener = React.useCallback(
async (message: TunnelbrokerToDeviceMessage) => {
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Oct 31, 2:36 PM (20 h, 5 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2392559
Default Alt Text
D13802.id45448.diff (1 KB)
Attached To
Mode
D13802: [lib] Make sure PeerToPeerMessageHandler is run after persisted state is read
Attached
Detach File
Event Timeline
Log In to Comment