Skip to content

Commit

Permalink
too big for browser
Browse files Browse the repository at this point in the history
  • Loading branch information
sonnyp committed Jan 1, 2025
1 parent d663a45 commit 434072b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
9 changes: 4 additions & 5 deletions packages/client/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,18 +64,17 @@ function client(options = {}) {
{ saslFactory, streamFeatures },
createOnAuthenticate(credentials ?? { username, password }, userAgent),
);
const fast = _fast({

const fast = setupIfAvailable(_fast, {
sasl2,
});
sasl2.setup({ fast });
fast && sasl2.setup({ fast });

// SASL2 inline features
const bind2 = _bind2({ sasl2, entity }, resource);

// sasl2.setupFast(fast);

// FAST mechanisms - order matters and define priority
htsha256none(fast.saslFactory);
fast && htsha256none?.(fast.saslFactory);

// Stream features - order matters and define priority
const sasl = _sasl(
Expand Down
4 changes: 3 additions & 1 deletion packages/client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@
"@xmpp/tcp": false,
"@xmpp/tls": false,
"@xmpp/starttls": false,
"@xmpp/sasl-scram-sha-1": false
"@xmpp/sasl-scram-sha-1": false,
"@xmpp/sasl-ht-sha-256-none": false,
"@xmpp/fast": false
},
"engines": {
"node": ">= 20"
Expand Down

0 comments on commit 434072b

Please sign in to comment.