Consider the following scenario:
- declare transaction
- receive a delivery
- detach the consumer
- send disposition with txn-state and Accepted outcome
- discharge the transaction
After this message should be deleted from the broker. It currently is not.
Currently, detaching the link applies the Modified outcome to all unsettled messages therefore the disposition and discharge have no effect on them.