If a customer spends £50 and uses a voucher to reduce that to £40 (for example) is the shop partner commission of 20% based on £50 or £40?

Thanks!