Skip to content

Fix merge request suggestions adding incorrect `+`

Phil Hughes requested to merge ph/454227/fixSuggestionPlus into master

What does this MR do and why?

Fixes a bug where if you add a suggestion on the changes tab and then switch to the overview tab, click reply and add a new suggestion it will add an invalid + symbol at the start. This happens because we don't call prepareDiffLines when a new note is added, only when notes are fetched.

#454227 (closed)

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

How to set up and validate locally

  • Create a suggestion on a diff line on the merge request changes tab
  • Click the overview tab
  • Reply to that discussion
  • Click the Insert suggestion button
  • There should be no + at the start.

Merge request reports