Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Merge pull request #312 from matrix-org/rav/eventlistnener_warning
Browse files Browse the repository at this point in the history
Fix eventListener warning
  • Loading branch information
dbkr committed Jun 16, 2016
2 parents 0cc4497 + 3e44d73 commit 624e34c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/MatrixClientPeg.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,11 @@ function createClientForPeg(hs_url, is_url, user_id, access_token, guestAccess)
}

matrixClient = Matrix.createClient(opts);

// we're going to add eventlisteners for each matrix event tile, so the
// potential number of event listeners is quite high.
matrixClient.setMaxListeners(500);

if (guestAccess) {
console.log("Guest: %s", guestAccess.isGuest());
matrixClient.setGuest(guestAccess.isGuest());
Expand Down Expand Up @@ -91,7 +96,7 @@ class MatrixClient {
}

// FIXME, XXX: this all seems very convoluted :(
//
//
// if we replace the singleton using URLs we bypass our createClientForPeg()
// global helper function... but if we replace it using
// an access_token we don't?
Expand Down

0 comments on commit 624e34c

Please sign in to comment.