Possible bug - clicking on "allocate payment" for payment entry changes paid amount

I have imported some credit card payments for testing and noticed that when I click “allocate payment” within the payment entry screen while the payment is still in draft, it changes the payment amount to the total outstanding balance. Does anyone know if this is intentional behaviour? If so, what is the reason for this?