Skip to content
This repository was archived by the owner on Mar 5, 2025. It is now read-only.

Add Support for Nethermind and Besu 'syncing' Subscription Payload Format #7306

Merged
merged 3 commits into from
Oct 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2729,6 +2729,12 @@ If there are any bugs, improvements, optimizations or any new feature proposal f

## [Unreleased]

### Added

#### web3-eth

- `syncing` subscription now supports Besu and Nethermind payload format

### Changed

#### web3-eth
Expand Down
2 changes: 1 addition & 1 deletion packages/web3-eth/src/web3_subscriptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ export class SyncingSubscription extends Web3Subscription<{
this.emit('changed', data);
} else {
const mappedData: SyncOutput = Object.fromEntries(
Object.entries(data.status).map(([key, value]) => [
Object.entries(data?.status || data).map(([key, value]) => [
key.charAt(0).toLowerCase() + key.substring(1),
value,
]),
Expand Down
Loading