Describe the bug
The Programs Comparison filter allows duplicate program selections, leading to console errors when trying to compare.
Steps to reproduce
- Set up a WordPress site running version ≥ 6.1.
- The filter cannot open on versions < 6.1 (see #1920).
- Navigate to the Reports → Programs tab.
- Click on the Programs filter and choose the Comparison filter.
- Use the search input to select a campaign.
- Search again and select the same campaign (duplicate).
- Click the Compare button.
- Observe the error in the browser console.
Expected behaviour
The filter should prevent selecting duplicate programs in the comparison search.
Actual behaviour
The filter allows duplicate selections, which results in a JavaScript console error.
Screenshot
