Skip to content

Instantly share code, notes, and snippets.

@mgraczyk
Created June 28, 2018 23:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mgraczyk/55b6c1799b0f992ee4509f702f72d653 to your computer and use it in GitHub Desktop.
Save mgraczyk/55b6c1799b0f992ee4509f702f72d653 to your computer and use it in GitHub Desktop.
case *messages.QueryRequest:
response := &messages.QueryResponse{}
if msg.Transaction != nil && msg.Transaction.Verify() {
stronglyPreferred := state.node.OnQueryTx(msg.Transaction)
response.Transaction = msg.Transaction.Id
response.StronglyPreferred = stronglyPreferred
ctx.Respond(response)
}
// [OT] Always respond with empty? Does this overwrite?
ctx.Respond(response)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment