Skip to content
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
1 change: 1 addition & 0 deletions api/handlers/signing.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ type SigningBody struct {
DepositTxHash string `json:"depositTxHash"`
BorrowAmount *BigInt `json:"borrowAmount"`
RepaymentChainId uint64 `json:"repaymentChainId"`
Deadline uint64 `json:"deadline"`
}

type SigningHandler struct {
Expand Down
5 changes: 1 addition & 4 deletions chains/lighter/message/lighter.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import (
"fmt"
"math/big"
"strconv"
"time"

"github.com/ethereum/go-ethereum/common"
"github.com/libp2p/go-libp2p/core/host"
Expand All @@ -26,7 +25,6 @@ import (

var (
ARBITRUM_CHAIN_ID = big.NewInt(42161)
FILL_DEADLINE = time.Minute * 5
)

type Coordinator interface {
Expand Down Expand Up @@ -109,8 +107,7 @@ func (h *LighterMessageHandler) HandleMessage(m *message.Message) (*proposal.Pro
h.usdcAddress,
ARBITRUM_CHAIN_ID,
h.lighterAddress,
//nolint:gosec
uint64(time.Now().Add(FILL_DEADLINE).Unix()),
data.Deadline,
data.Caller,
data.LiquidityPool,
data.Nonce)
Expand Down
1 change: 1 addition & 0 deletions chains/lighter/message/message.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ type LighterData struct {
Calldata string
Nonce *big.Int
BorrowAmount *big.Int
Deadline uint64
Source uint64
Destination uint64
}
Expand Down
Loading