composer-default doesn't handle complicated usernames
-
I ran across an obscure bug. I am sure it is low priority but I figured I would log it for future reference...
nodebb-plugin-composer-default
fails to correctly display complex usernames when 'mentioning' the user. Specifically, any username characters that require escaping are replaced with '-'. The three guilty characters that I discovered are '*', '.', and '+' . There may be others.For example, a user named John.Doe would be mentioned as @John-Doe.
This does not affect 'mention' functionality, as the links and notifications remain intact. It would however affect things like text-based searches for usernames. ...A complex username also apparently breaks
nodebb-plugin-dbsearch
, for it cannot find any posts from my strangely-named user. -
...Oh, I get it now. Usernames are slugified on purpose.
Regarding the search error, it happens specifically on my user named "Complex-x*x+x.x". Search cannot find this user's posts. When I re-open the
Posted by
input in `nodebb-plugin-dbsearch' that user gets replaced by "Guest".(v3.1.6)