Fix calling wrong method in README for ws (#26631)

The documentation is wrong. The WebSocketClient.authorize() is not a method of WebSocketClient. The right method is WebSocketClient.initialize()
Этот коммит содержится в:
Lars Bo Rasmussen
2024-04-18 20:23:59 +02:00
коммит произвёл GitHub
родитель 02e23a3275
Коммит b4b760274d

Просмотреть файл

@@ -76,7 +76,7 @@ const connectionUrl = 'https://mymattermostserver.example.com/api/v4/websocket';
const authToken = process.env.TOKEN;
const wsClient = new WebSocketClient();
wsClient.authorize(connectionUrl, authToken);
wsClient.initialize(connectionUrl, authToken);
wsClient.addMessageListener((msg) => {
if (msg.event === 'posted') {