minor changes to discount code management