mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-05-26 17:24:56 +00:00
Revert "AAE-20808 Fixed websocket protocol (#10433)"
This reverts commit 48e9d56453b2908ab7dd1737b128aaf8b53b564c.
This commit is contained in:
parent
efa4a53a36
commit
a6a2dc1abc
@ -95,13 +95,9 @@ export class WebSocketService extends BaseCloudService {
|
||||
|
||||
private createWsUrl(apolloClientName: string, serviceUrl: string): string {
|
||||
const url = new URL(serviceUrl, this.host);
|
||||
const protocol2 = url.protocol === 'https:' ? 'wss:' : 'ws:';
|
||||
url.protocol = protocol2;
|
||||
const protocol = this.host.split('://')[0] === 'https' ? 'wss' : 'ws';
|
||||
const subHost = this.host.split('://')[1];
|
||||
const finalUrl = `${protocol}://${subHost}/${apolloClientName}/notifications`;
|
||||
this.logger.error(`WebSocketService: createWsUrl: ${finalUrl}`);
|
||||
return finalUrl;
|
||||
url.protocol = url.protocol === 'https' ? 'wss' : 'ws';
|
||||
|
||||
return url.href;
|
||||
}
|
||||
|
||||
private createHttpUrl(serviceUrl: string): string {
|
||||
|
Loading…
x
Reference in New Issue
Block a user