[bugfix] accounting error when swapping from synth --> rune

found accounting bugs in swapping from a synthetic asset --> rune (but not the other way). In addition, when swapping sythn --> synth, we also had accounting problems.

To mitigate this issue, whenever swapping to rune, also mint the rune during the swap, instead of minting it during the txout manager. This gives more consistent behavior between all 8 possible ways a swap can happen, which are...

| layer1 --> Rune   |
| Rune --> layer1   |
| Layer1 --> Layer1 |
| Layer2 --> Rune   |
| Rune --> Layer2   |
| layer2 --> layer2 |
| layer2 --> layer1 |
| Layer1 --> layer2 |
Edited by Son of Odin

Merge request reports

Loading