forked from forgejo/forgejo
Allow 's
in mentions
When mentioning a user in a comment, or a similar place, sometimes one would wish to use a possessive: `As per @user's suggestion` or somesuch. This patch modifies the `mentionPattern` used to find mentions, to allow - and then ignore - apostrophes and whatever comes after them. Signed-off-by: Gergely Nagy <forgejo@gergo.csillger.hu>
This commit is contained in:
parent
c39321c6ca
commit
00b24d2d9a
3 changed files with 9 additions and 1 deletions
|
@ -392,6 +392,9 @@ func TestRegExp_mentionPattern(t *testing.T) {
|
|||
{"@gitea,", "@gitea"},
|
||||
{"@gitea;", "@gitea"},
|
||||
{"@gitea/team1;", "@gitea/team1"},
|
||||
{"@jess'", "@jess"},
|
||||
{"@forgejo's", "@forgejo"},
|
||||
{"Оно сломалось из-за коммитов от @jopik'а", "@jopik"},
|
||||
}
|
||||
falseTestCases := []string{
|
||||
"@ 0",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue