Skip to content

Commit

Permalink
added encodedtx to broadcast transaction response
Browse files Browse the repository at this point in the history
  • Loading branch information
0xluk committed Apr 5, 2024
1 parent 7478637 commit 23fb2a9
Show file tree
Hide file tree
Showing 3 changed files with 69 additions and 57 deletions.
2 changes: 1 addition & 1 deletion foundation/rpc_server/rpc_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ func (s *Server) BroadcastTransaction(ctx context.Context, req *protobuff.Broadc
if err != nil {
return nil, status.Error(codes.InvalidArgument, err.Error())
}
return &protobuff.BroadcastTransactionResponse{PeersBroadcasted: int32(broadcastTxToMultiple(ctx, s.qPool, decodedTx))}, nil
return &protobuff.BroadcastTransactionResponse{PeersBroadcasted: int32(broadcastTxToMultiple(ctx, s.qPool, decodedTx)), EncodedTransaction: req.EncodedTransaction}, nil
}

func broadcastTxToMultiple(ctx context.Context, pool *qubic.Pool, decodedTx []byte) int {
Expand Down
123 changes: 67 additions & 56 deletions protobuff/qubic.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions protobuff/qubic.proto
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ message BroadcastTransactionRequest {

message BroadcastTransactionResponse {
int32 peers_broadcasted = 1;
string encoded_transaction = 2;
}

message TickInfo {
Expand Down

0 comments on commit 23fb2a9

Please sign in to comment.