OSDN Git Service

update
authorChengcheng Zhang <943420582@qq.com>
Tue, 10 Sep 2019 14:00:56 +0000 (22:00 +0800)
committerChengcheng Zhang <943420582@qq.com>
Tue, 10 Sep 2019 14:00:56 +0000 (22:00 +0800)
swap/htlc.go
swap/trade_offer.go

index cb867ea..dce4138 100644 (file)
@@ -335,7 +335,7 @@ func signUnlockHTLCContractTransaction(account AccountInfo, preimage, recipientS
        return res.Tx.RawTransaction, nil
 }
 
-func DecodeHTLCProgram(program string) (*HTLCContractArgs, error) {
+func decodeHTLCProgram(program string) (*HTLCContractArgs, error) {
        payload, err := json.Marshal(decodeProgramReq{Program: program})
        if err != nil {
                return nil, err
index d611984..e116814 100644 (file)
@@ -243,7 +243,7 @@ func buildUnlockContractTransaction(accountInfo AccountInfo, contractUTXOID stri
                return "", err
        }
 
-       contractArgs, err := DecodeProgram(program)
+       contractArgs, err := decodeProgram(program)
        if err != nil {
                return "", err
        }
@@ -314,7 +314,7 @@ type decodeProgramReq struct {
        Program string `json:"program"`
 }
 
-func DecodeProgram(program string) (*ContractArgs, error) {
+func decodeProgram(program string) (*ContractArgs, error) {
        payload, err := json.Marshal(decodeProgramReq{Program: program})
        if err != nil {
                return nil, err