You've already forked matrix-js-sdk
mirror of
https://github.com/matrix-org/matrix-js-sdk.git
synced 2025-11-28 05:03:59 +03:00
Hit /versions instead of / since it is actually a known endpoint
This commit is contained in:
11
lib/sync.js
11
lib/sync.js
@@ -562,14 +562,9 @@ SyncApi.prototype._sync = function(syncOptions, attempt) {
|
|||||||
*/
|
*/
|
||||||
SyncApi.prototype._pokeKeepAlive = function() {
|
SyncApi.prototype._pokeKeepAlive = function() {
|
||||||
return this.client._http.requestWithPrefix(
|
return this.client._http.requestWithPrefix(
|
||||||
undefined, "GET", "/", undefined,
|
undefined, "GET", "/_matrix/client/versions", undefined,
|
||||||
undefined, httpApi.PREFIX_R0, 5 * 1000
|
undefined, "", 5 * 1000
|
||||||
).catch(function(err) {
|
);
|
||||||
if (err.httpStatus > 0) { // we hit the server alright
|
|
||||||
return q();
|
|
||||||
}
|
|
||||||
throw err;
|
|
||||||
});
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ describe("MatrixClient", function() {
|
|||||||
var identityServerDomain = "identity.server";
|
var identityServerDomain = "identity.server";
|
||||||
var client, store, scheduler;
|
var client, store, scheduler;
|
||||||
|
|
||||||
var KEEP_ALIVE_PATH = "/";
|
var KEEP_ALIVE_PATH = "/_matrix/client/versions";
|
||||||
|
|
||||||
var PUSH_RULES_RESPONSE = {
|
var PUSH_RULES_RESPONSE = {
|
||||||
method: "GET",
|
method: "GET",
|
||||||
|
|||||||
Reference in New Issue
Block a user