diff options
author | RaindropsSys <contact@minteck.org> | 2023-05-06 12:42:09 +0200 |
---|---|---|
committer | RaindropsSys <contact@minteck.org> | 2023-05-06 12:42:09 +0200 |
commit | 10f4e309040b3a5f8922168c288b64658a4efb8c (patch) | |
tree | ffa2135eda3adb35a8d19d357f11e4babdd758fe | |
parent | 8cdbff7146e81546143f1f54e75bfd0eb34d17a0 (diff) | |
download | pluralconnect-10f4e309040b3a5f8922168c288b64658a4efb8c.tar.gz pluralconnect-10f4e309040b3a5f8922168c288b64658a4efb8c.tar.bz2 pluralconnect-10f4e309040b3a5f8922168c288b64658a4efb8c.zip |
Updated includes/external/matrix/index.js (automated)
-rw-r--r-- | includes/external/matrix/index.js | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/includes/external/matrix/index.js b/includes/external/matrix/index.js index b8ae194..cd26a87 100644 --- a/includes/external/matrix/index.js +++ b/includes/external/matrix/index.js @@ -15,6 +15,12 @@ const client = sdk.createClient({ userId: "@" + user + ":equestria.dev" }); +function sleep(ms) { + return new Promise((res, rej) => { + setTimeout(res, ms); + }); +} + client.once("sync", async function (state, prevState, res) { if (state === "PREPARED") { console.log("Ready"); @@ -56,6 +62,8 @@ client.once("sync", async function (state, prevState, res) { } }); + await sleep(2000); + console.log("Uploading avatar"); let pfp; |