Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Use explicit getters and setters for common properties #243

Merged
merged 2 commits into from Feb 15, 2024

Conversation

frereit
Copy link
Collaborator

@frereit frereit commented Feb 15, 2024

This ensures values are correctly escaped.

When setting properties using SetDescription, it is escaped. This ensures a well-formed iCal file. Using GetDescription returns the unescaped string, resulting in a well-rendered frontend.

This is blocked by JM-Lemmi/golang-ical#7. Merging before that PR is merged, and then incorporated back into this repository via the submodule, will break things.

This ensures values are correctly escaped.

When setting properties using SetDescription, it is escaped. This
ensures a well-formed iCal file. Using GetDescription returns the
unescaped string, resulting in a well-rendered frontend.
@frereit frereit marked this pull request as draft February 15, 2024 17:53
@JM-Lemmi JM-Lemmi added bug Something isn't working backend api and backend related labels Feb 15, 2024
@frereit frereit marked this pull request as ready for review February 15, 2024 18:11
@JM-Lemmi JM-Lemmi merged commit f131b61 into beta_2.0 Feb 15, 2024
4 checks passed
@JM-Lemmi JM-Lemmi deleted the fix/use_escaped_getters_and_setters branch February 15, 2024 19:59
@JM-Lemmi
Copy link
Owner

JM-Lemmi commented Feb 15, 2024

Fixing files that were ruined by this bug:

find the number of files that contain three or more backslashes: grep -le '\\\\\\' * | wc -l

replace three backslashes by two backslashes: find /etc/ical-relay/calstore/ -type f -exec sed -i 's/\\\\\\/\\\\/g' {} +

replace any leftover lines that only contain two backslashes: find /etc/ical-relay/calstore/ -type f -exec sed -i '/ \\\\/d' {} +

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend api and backend related bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants