Skip to content

Commit ff769df

Browse files
Removing the protocol handler (?uri=...)
1 parent baaced6 commit ff769df

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

src/plugins/chatview/utils.js

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -124,12 +124,7 @@ export async function routeToQueryAction(event) {
124124
*/
125125
function extractXMPPURI(event) {
126126
let uri = null;
127-
128-
// Case 1: protocol handler (?uri=...)
129-
const searchParams = new URLSearchParams(window.location.search);
130-
uri = searchParams.get('uri');
131-
132-
// Case 2: hash-based (#converse/action?uri=...)
127+
// hash-based (#converse/action?uri=...)
133128
if (!uri && location.hash.startsWith('#converse/action?uri=')) {
134129
event?.preventDefault();
135130
uri = location.hash.split('uri=').pop();
@@ -153,8 +148,8 @@ function extractXMPPURI(event) {
153148
*/
154149
function parseXMPPURI(uri) {
155150
const [jid, query] = uri.split('?');
156-
const queryParams = new URLSearchParams(query);
157-
return { jid, queryParams };
151+
const query_params = new URLSearchParams(query);
152+
return { jid, query_params };
158153
}
159154

160155
/**

0 commit comments

Comments
 (0)