Fix a bug and performance issue in promotions editing widget.