Fixed the flat discount issue

Fixed the flat discount issue