Repository navigation
Fixed bug with tag-raw not working with code snippets - #271
Merged
Merged
Conversation
* it didnt escape ``` correctly (\``` instead of \`\`\`) * adjusted test cases * added a new test case to cover this (and other more complex situations)
Zabuzard
requested review from
Tais993,
illuminator3,
java-coding-prodigy and
marko-radosavljevic
November 19, 2021 12:33
Zabuzard
enabled auto-merge (rebase)
November 19, 2021 12:33
|
Kudos, SonarCloud Quality Gate passed! |
Contributor
|
Could you share a screenshot of the output after fixing the bug? |
Member
Author
Member
Author
|
That said, I spot another bug. Embeds seem to mess up leading spaces (they are part of the message though). It doesnt seem like this is fixable though... |
marko-radosavljevic
approved these changes
Nov 20, 2021
marko-radosavljevic
left a comment
Contributor
There was a problem hiding this comment.
Tests failed to catch this, and if I reviewed this code (and tests) I wouldn't catch it either. Just something to note. ^^
illuminator3
previously requested changes
Nov 23, 2021
Member
Author
|
Been a week since the last change. Got one approval by marko and one semi approval by illu (I guess). Merging. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.









Bug
Fixes #269 .
Basically,
/tag-manage rawdid not escape triple backticks correctly.Resulting in crap like this:
Fix
The fix applied here is relatively simple, we still use the existing escaping utility but apply a patch on top where we replace its result with the proper result.
I slightly rewrote the code section to make it clearer that we now have a replace before and one after the escape utility. Otherwise its too easy to confuse with two replacements happening before, i.e.
I also adjusted the existing test cases and added a new unit test to cover this particular complex case as well.