integreat-cms
integreat-cms copied to clipboard
Fix sending feedback for recurring events
Short description
Slugs for recurring events contain date (in format: base-slug$yyyy-mm-dd). As a result, when we receive a feedback for recurring event, event can't found by slug in DB and response 404 is returned.
Proposed changes
Remove the date from the slug during feedback processing
Side effects
- If someone manually creates event with the slug ending with the date in format $yyyy-mm-dd, feedback for such event won't be processed (upd: actually not possible, symbol $ is not allowed in the slug)
- There is no validation of the date in slug. If we receive feedback for an existing event but with an nonexistent date, it will be processed successfully.
- We lose information about which date the feedback belongs to.
Resolved issues
Fixes: #1793
Code Climate has analyzed commit 35977bfb and detected 0 issues on this pull request.
The test coverage on the diff in this pull request is 100.0% (50% is the threshold).
This pull request will bring the total coverage in the repository to 74.2% (0.0% change).
View more on Code Climate.