Merge branch 'websocket-wallet-tx-updates'

This commit is contained in:
padreug 2025-09-18 11:21:57 +02:00
commit 5df65a50d2

View file

@ -406,10 +406,11 @@ export class WalletWebSocketService extends BaseService {
private sendPing(): void { private sendPing(): void {
if (this.ws && this.ws.readyState === WebSocket.OPEN) { if (this.ws && this.ws.readyState === WebSocket.OPEN) {
try { try {
// Send a ping frame (most WebSocket implementations support this) // Send a simple ping message (browser WebSocket doesn't have ping method)
this.ws.ping?.() // Most WebSocket servers respond to text messages as keepalive
this.ws.send(JSON.stringify({ type: 'ping' }))
} catch (error) { } catch (error) {
console.log('WalletWebSocketService: Ping not supported, connection seems stable') console.log('WalletWebSocketService: Ping failed, connection may be unstable')
} }
} }
} }