Skip to content

Conversation

@nickvergessen
Copy link
Member

@nickvergessen nickvergessen commented Nov 6, 2024

Summary

Some apps were using placeholders with spaces, @ and slashes. But the frontend only allowed [a-z\-_.0-9]+
https://github.com/nextcloud-libraries/nextcloud-vue/blob/master/src/components/NcRichText/NcRichText.vue#L396-L397
At the same time, using 0-9 only would break in PHP as that makes it not a string anymore but a number, so additionally we now require the placeholder to start with a-zA-Z

The recommended workaround is to not use "user ids" and other things directly, but instead using hardcoded strings like actor or "counting keys" like user-1, similar to how comments does it on it's activities:

Checklist

@nickvergessen nickvergessen added bug 3. to review Waiting for reviews labels Nov 6, 2024
@nickvergessen nickvergessen added this to the Nextcloud 31 milestone Nov 6, 2024
@nickvergessen nickvergessen requested review from a team and come-nc November 6, 2024 20:41
@nickvergessen nickvergessen self-assigned this Nov 6, 2024
@nickvergessen nickvergessen requested review from ArtificialOwl and provokateurin and removed request for a team November 6, 2024 20:41
@nickvergessen nickvergessen added the pending documentation This pull request needs an associated documentation update label Nov 6, 2024
Copy link
Member

@provokateurin provokateurin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

@come-nc come-nc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good apart from typo

@nickvergessen nickvergessen requested a review from come-nc November 7, 2024 09:38
@nickvergessen nickvergessen merged commit 31f4f67 into master Nov 7, 2024
175 of 177 checks passed
@nickvergessen nickvergessen deleted the bugfix/noid/validate-parameter-keys branch November 7, 2024 13:25
@skjnldsv skjnldsv mentioned this pull request Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review Waiting for reviews bug pending documentation This pull request needs an associated documentation update

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants