mirror of
https://github.com/comit-network/xmr-btc-swap.git
synced 2024-12-24 15:09:35 -05:00
b417950f99
Instead of forwarding every error, we deliberately ignore certain variants that are not worth being printed to the log. In particular, this concerns "UnsupportedProtocols" and "ResponseOmission". To make this less verbose we introduce a macro for mapping a `RequestResponseEvent` to `{alice,bob}::OutEvent`. We use a macro because those `OutEvent`s are different types and the only other way of abstracting over them would be to introduce traits that we implement on both of them. To make the macro easier to use, we move all the `From` implementations that convert between the protocol and the more high-level behaviour into the actual protocol module. |
||
---|---|---|
.. | ||
src | ||
tests | ||
Cargo.toml |