mirror of
https://github.com/comit-network/xmr-btc-swap.git
synced 2025-03-19 04:46:17 -04:00

The `EventLoop` will use the `Builder` interface to instantiate a `Swap` upon receiving a `SwapRequest` and successfully doing an execution setup. Before this change, the `EventLoop` would have to hold the path to the db and re-open the db everytime it wants to construct a swap. With this change, we can open the DB once and then hold a `Arc<Database>` in the `EventLoop` and pass it to new `Swap`s structs.