Skip to content

Commit 6c7acec

Browse files
committed
feat(): fix uploader bug
1 parent 18b53e7 commit 6c7acec

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

uploader.go

+14-14
Original file line numberDiff line numberDiff line change
@@ -415,10 +415,10 @@ func (tt *TransactionUploader) postTransaction() error {
415415
}
416416

417417
func (tt *TransactionUploader) uploadTx(withBody bool) error {
418-
if withBody {
419-
// Post the Transaction with Data.
420-
tt.Transaction.Data = utils.Base64Encode(tt.Data)
421-
}
418+
// if withBody {
419+
// // Post the Transaction with Data.
420+
// tt.Transaction.Data = utils.Base64Encode(tt.Data)
421+
// }
422422
body, statusCode, err := tt.Client.SubmitTransaction(tt.Transaction)
423423
if err != nil || statusCode >= 400 {
424424
tt.LastResponseError = fmt.Sprintf("%v,%s", err, body)
@@ -429,22 +429,22 @@ func (tt *TransactionUploader) uploadTx(withBody bool) error {
429429
tt.LastRequestTimeEnd = time.Now().UnixNano() / 1000000
430430
tt.LastResponseStatus = statusCode
431431

432-
if withBody {
433-
tt.Transaction.Data = ""
434-
}
432+
// if withBody {
433+
// tt.Transaction.Data = ""
434+
// }
435435

436436
// tx already processed
437437
if statusCode >= 200 && statusCode < 300 {
438438
tt.TxPosted = true
439-
if withBody {
440-
// We are complete.
441-
tt.ChunkIndex = types.MAX_CHUNKS_IN_BODY
442-
}
439+
// if withBody {
440+
// // We are complete.
441+
// tt.ChunkIndex = types.MAX_CHUNKS_IN_BODY
442+
// }
443443
return nil
444444
}
445445

446-
if withBody {
447-
tt.LastResponseError = ""
448-
}
446+
// if withBody {
447+
// tt.LastResponseError = ""
448+
// }
449449
return nil
450450
}

0 commit comments

Comments
 (0)