Skip to content

Commit

Permalink
refactor: remove 0x prefix from address
Browse files Browse the repository at this point in the history
  • Loading branch information
nugaon committed Sep 25, 2023
1 parent 953633d commit e1cde71
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions pkg/storageincentives/redistribution/inclusionproof.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import (
"encoding/binary"
"encoding/hex"

"github.com/ethereum/go-ethereum/common"
"github.com/ethersphere/bee/pkg/bmt"
"github.com/ethersphere/bee/pkg/soc"
"github.com/ethersphere/bee/pkg/storer"
Expand Down Expand Up @@ -50,10 +49,10 @@ type PostageProof struct {
// SOCProof structure must exactly match
// corresponding structure (of the same name) in Redistribution.sol smart contract.
type SOCProof struct {
Signer common.Address `json:"signer"`
Signature string `json:"signature"`
Identifier string `json:"identifier"`
ChunkAddr string `json:"chunkAddr"`
Signer string `json:"signer"`
Signature string `json:"signature"`
Identifier string `json:"identifier"`
ChunkAddr string `json:"chunkAddr"`
}

// Transforms arguments to ChunkInclusionProof object
Expand Down Expand Up @@ -97,7 +96,7 @@ func makeSOCProof(sampleItem storer.SampleItem) ([]SOCProof, error) {
}

return []SOCProof{{
Signer: common.Address(socCh.OwnerAddress()),
Signer: hex.EncodeToString(socCh.OwnerAddress()),
Signature: hex.EncodeToString(socCh.Signature()),
Identifier: hex.EncodeToString(socCh.ID()),
ChunkAddr: hex.EncodeToString(socCh.WrappedChunk().Address().Bytes()),
Expand Down

0 comments on commit e1cde71

Please sign in to comment.