Skip to content

Commit

Permalink
docs: fix the errors
Browse files Browse the repository at this point in the history
  • Loading branch information
danijelTxFusion committed Nov 6, 2024
1 parent 1b2bf80 commit eaa4a7b
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ fmt.Printf("%+v\n", block)

```ts
privateKey := os.Getenv("PRIVATE_KEY")
w, err := accounts.NewWallet(common.Hex2Bytes(privateKey), &client, ethClient)
w, err := accounts.NewWallet(common.Hex2Bytes(privateKey), client, ethClient)
if err != nil {
log.Panic(err)
}
Expand All @@ -108,7 +108,7 @@ if err != nil {
### Check account balances

```go
balance, err := w.Balance(context.Background(), utils.EthAddress, nil) // balance on ZKsync Era network
balance, err := w.Balance(nil, utils.EthAddress) // balance on ZKsync Era network
if err != nil {
log.Panic(err)
}
Expand All @@ -131,7 +131,7 @@ chainID, err := client.ChainID(context.Background())
if err != nil {
log.Panic(err)
}
receiver, err := accounts.NewRandomWallet(chainID.Int64(), &client, ethClient)
receiver, err := accounts.NewRandomWallet(chainID.Int64(), client, ethClient)
if err != nil {
log.Panic(err)
}
Expand Down Expand Up @@ -169,9 +169,9 @@ Transfer funds from L2 to L1 network.

```ts
tx, err := w.Withdraw(accounts.WithdrawalTransaction{
To: w.Address(),
Amount: big.NewInt(1_000_000_000_000_000_000),
Token: utils.EthAddress,
To: w.Address(),
Amount: big.NewInt(1_000_000_000_000_000_000),
Token: utils.EthAddress,
})
if err != nil {
log.Panic(err)
Expand Down
2 changes: 1 addition & 1 deletion clients/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import (
)

// Client provides RPC methods on ZKsync Era node.
// Interface contains same methods as ethclient.Client except for FeeHistory method.
// Contains same methods as ethclient.Client except for FeeHistory method.
// Additionally, it has extra methods capable of working with EIP712 transactions.
// It is designed to be compatible with bind.ContractBackend interface, enabling support for
// smart contracts generated using the abigen tool.
Expand Down
2 changes: 1 addition & 1 deletion types/call_msg.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"math/big"
)

// CallMsg contains parameters for contract call using EIP-712 transaction.
// CallMsg contains parameters for contract call using L2 transaction.
type CallMsg struct {
From common.Address // The sender of the 'transaction'.
To *common.Address // The destination contract (nil for contract creation).
Expand Down
2 changes: 1 addition & 1 deletion types/transaction.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
// TxType represents a L2 transaction type.
const TxType = `0x71`

// Transaction provides support for ZKsync Era-specific features
// Transaction provides support for ZKsync specific features
// such as account abstraction and paymasters.
// Smart contracts must be deployed with this transaction type.
type Transaction struct {
Expand Down

0 comments on commit eaa4a7b

Please sign in to comment.