Discount code bug fix