Page MenuHomePhabricator

Trim question before posting on-wiki
Closed, ResolvedPublic


If your question contains a newline at its end, it will cause the signature to be malformed, see Since I don't see a reason for allowing newlines (or any other whitespace chars) at the start or end of a question (such whitespace will probably be an user's mistake rather than intention), I think we should trim question before doing all of QuestionPoster logic.

This affects mentorship questions, helpdesk question from Homepage and help pane questions.

Real on-wiki example:


Related Gerrit Patches:
mediawiki/extensions/GrowthExperiments : masterTrim question in QuestionPoster's constructor

Event Timeline

Restricted Application added projects: Growth-Team, User-Urbanecm. · View Herald TranscriptJul 13 2019, 12:16 PM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript

Change 522593 had a related patch set uploaded (by Urbanecm; owner: Urbanecm):
[mediawiki/extensions/GrowthExperiments@master] Trim question in QuestionPoster's constructor

Urbanecm triaged this task as Medium priority.Jul 14 2019, 12:33 PM

Change 522593 merged by jenkins-bot:
[mediawiki/extensions/GrowthExperiments@master] Trim question in QuestionPoster's constructor

Etonkovidova closed this task as Resolved.Jul 30 2019, 8:20 PM