Improve code structure and error messages for running swaps

The quote message was repeated and we should set the overall
failure into a context to know what went wrong.
This commit is contained in:
Thomas Eizinger 2021-03-18 17:48:54 +11:00
parent 0c0a322a8f
commit 2c9ab4f6eb
No known key found for this signature in database
GPG key ID: 651AC83A6C6C8B96
2 changed files with 10 additions and 10 deletions

View file

@ -223,7 +223,7 @@ impl EventLoop {
}
OutEvent::ResponseSent => {}
OutEvent::CommunicationError(err) => {
bail!("Communication error: {:#}", err)
bail!(err.context("Communication error"))
}
}
},