Refunding via graphql removes every line item from order except one qty of line item

A cart consists of 3 qty of x and 3 of y. When 1 qty of a line item x is fulfilled and a graphql refundCreate mutation is executed to refund the remaining quantities of x (2) and y (3) the refund operation removes y successfully but leaves 1 qty of x as unfulfilled. The log of the refund confirms that 3 of x and 3 of y were removed and the cart totals are correct - there just appears to be an error in the cart state.