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()
This commit is contained in:
Lars Bo Rasmussen 2024-04-18 20:23:59 +02:00 committed by GitHub
parent 02e23a3275
commit b4b760274d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -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') {