My customer's payment applied to wrong invoice.

Here's how to fix that!

Go to Financial Reports >Transaction Report and UNDO the payment on the incorrect invoice.

This does not refund the customer's payment, it just reverts which invoice it was applied to.

THEN you'll go to the correct invoice, apply a MANUAL payment (again because you already have the customer's money, they don't need to be charged again) and just make a note that this payment was incorrectly applied to another invoice and manually applied to the correct invoice.