Quick actions are not recognised when editing comment or description

The implemented solution only works for editing of comments, not descriptions of Issues or MRs

Summary

Let's assume I misspelled a slash command and let's say I wrote:

/assign @eservais

When editing assing to assign, gitlab won't interpret the corrected command and will let the command in the text body, and won't interpret it. As a consequence, I shall delete it and make the assignment another way (either in a new comment or with my mouse 😮 )

Maybe there is a way to improve this?

Tested on GitLab Community Edition 8.11.0 346e677e

Steps to Reproduce

  • Create a new issue
  • Comment on the issue with a misspelled slash command e.g. /titel My new title
  • Submit the comment
  • Edit the comment to correct the mistake

Expected Results

Editing to correct slash command will perform the action

https://gitlab.com/gitlab-org/gitlab-ce/issues/21505#note_15386756 notes:

The edge case of a comment with only commands would have to be well handled, though: the note should be deleted (from the DB and the UI) if its content is blank after commands interpretation.

Actual Results

Comment is posted with the correct edition but no slash command operation is executed

Additional Information

Issue exhibiting the behaviour: issue-reproduce/slash-commands-edit#1

Edited by Tim Poffenbarger