diff --git a/chains/evm/signature/hash.go b/chains/evm/signature/hash.go index f7bc0e97..95565357 100644 --- a/chains/evm/signature/hash.go +++ b/chains/evm/signature/hash.go @@ -8,6 +8,7 @@ import ( "github.com/ethereum/go-ethereum/common/math" "github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/signer/core/apitypes" + "github.com/rs/zerolog/log" ) const ( @@ -78,7 +79,9 @@ func BorrowUnlockHash( } rawData := []byte(fmt.Sprintf("\x19\x01%s%s", string(domainSeparator), string(messageHash))) - return crypto.Keccak256(rawData), nil + unlockHash := crypto.Keccak256(rawData) + log.Debug().Msgf("Created unlock hash %s with data: %+v", common.Bytes2Hex(unlockHash), msg) + return unlockHash, nil } // BorrowManyUnlockHash calculates the hash that has to be signed and submitted on-chain to the liquidity diff --git a/protocol/lighter/api.go b/protocol/lighter/api.go index db5c03d1..01a26ecf 100644 --- a/protocol/lighter/api.go +++ b/protocol/lighter/api.go @@ -82,8 +82,6 @@ func (a *LighterAPI) GetTx(hash string) (*LighterTx, error) { return nil, fmt.Errorf("failed to read response body: %w", err) } - fmt.Println(string(body)) - s := new(LighterTx) if err := json.Unmarshal(body, s); err != nil { return nil, fmt.Errorf("failed to unmarshal JSON: %w", err)