__Problem__: `window.jamClient = jamClient;` was polluting the global scope, preventing garbage collection of the jamClient object and creating potential memory leaks.
__Solution__: Removed the global assignment entirely since: - The `jamClient` is already available through `JamServerContext` - No usage of `window.jamClient` was found in the codebase - The comment mentioned "iframe access" but this can be handled through proper React patterns if needed
This commit is contained in:
parent
b193fb299a
commit
d6ec0a3406
|
|
@ -155,9 +155,6 @@ const JKSessionScreen = () => {
|
|||
if (!isConnected || !jamClient) return;
|
||||
console.debug("JKSessionScreen: -DEBUG- isConnected changed to true");
|
||||
|
||||
// Make jamClient available globally for iframe access
|
||||
window.jamClient = jamClient;
|
||||
|
||||
guardOnJoinSession();
|
||||
}, [isConnected, jamClient]); // Added jamClient to dependencies for stability
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue