How? Cheating is, well, cheating on your implicit agreement with your spouse/partner. Prostitution, when done correctly, is a consensual agreement between two people.
Essentially, there's no case in which cheating is not "wrong." There's many where prostitution isn't.
Essentially, there's no case in which cheating is not "wrong." There's many where prostitution isn't.