@signalapp/mock-server
Advanced tools
Comparing version 10.0.1 to 10.1.0
{ | ||
"name": "@signalapp/mock-server", | ||
"version": "10.0.1", | ||
"version": "10.1.0", | ||
"description": "Mock Signal Server for writing tests", | ||
@@ -5,0 +5,0 @@ "main": "src/index.js", |
@@ -601,3 +601,6 @@ "use strict"; | ||
} | ||
if (url.startsWith('/v1/websocket/provisioning')) { | ||
// Use a fixed string instead of constructing the URL from the HOST header | ||
// since we don't actually care about anything but the path. | ||
const path = new URL(url, 'http://localhost').pathname; | ||
if (path.startsWith('/v1/websocket/provisioning')) { | ||
const id = await this.server.generateProvisionId(); | ||
@@ -613,5 +616,8 @@ try { | ||
} | ||
if (url.startsWith('/v1/websocket/?')) { | ||
if (path === '/v1/websocket/') { | ||
return await this.handleNormal(this.request); | ||
} | ||
else { | ||
debug('websocket connection has unexpected URL %s', url); | ||
} | ||
} | ||
@@ -618,0 +624,0 @@ async sendMessage(message) { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
3949428
72838
1