Removed debugging console log

This commit is contained in:
Charles 2025-11-25 15:04:13 +01:00
parent 94c0fd7c42
commit f09dd20d2b
1 changed files with 3 additions and 5 deletions

View File

@ -78,18 +78,16 @@ export default class extends Controller {
// If closed, log it for debugging.
try {
if (this.eventSource.readyState === EventSource.CLOSED) {
console.log('Connection closed. Will retry...');
console.log();
} else if (this.eventSource.readyState === EventSource.CONNECTING) {
console.log('Connection is reconnecting (CONNECTING).');
console.log();
} else if (this.eventSource.readyState === EventSource.OPEN) {
console.log('Connection is open (OPEN).');
console.log();
}
} catch (e) {
console.error('Error while checking EventSource state:', e);
}
};
console.log('EventSource connected to:', url.toString());
} catch (error) {
console.error('Failed to connect to Mercure:', error);
}