(feat): add crypto interface for MTPClient in wasm
Some checks failed
CI / rustfmt (push) Successful in 17s
CI / wasm build (push) Successful in 1m18s
CI / clippy (push) Successful in 1m32s
CI / test (push) Successful in 1m53s
CI / example (push) Successful in 1m35s
CI / duplicate code (push) Failing after 31s
CI / web client (push) Failing after 32s
CI / cargo-machete (push) Successful in 1m9s
CI / cargo-deny (push) Failing after 2m31s
Some checks failed
CI / rustfmt (push) Successful in 17s
CI / wasm build (push) Successful in 1m18s
CI / clippy (push) Successful in 1m32s
CI / test (push) Successful in 1m53s
CI / example (push) Successful in 1m35s
CI / duplicate code (push) Failing after 31s
CI / web client (push) Failing after 32s
CI / cargo-machete (push) Successful in 1m9s
CI / cargo-deny (push) Failing after 2m31s
(qol): update readme (fix): small bug in keypair.rs
This commit is contained in:
parent
04d6240452
commit
6b9bbb6ebf
6 changed files with 144 additions and 29 deletions
|
|
@ -199,7 +199,10 @@ async function connect() {
|
|||
log(`Subscribed Pong: ${formatParsedFrame(frame)}`, "received");
|
||||
});
|
||||
|
||||
const activeClientId = await client.connectOrRegister();
|
||||
const existingClientId = client.credentials?.clientId;
|
||||
const activeClientId = existingClientId == null
|
||||
? await client.register()
|
||||
: (await client.connect(), BigInt(existingClientId));
|
||||
clientId = activeClientId;
|
||||
loadKeys();
|
||||
log(`Connected as client ${activeClientId}`);
|
||||
|
|
|
|||
Loading…
Reference in a new issue