Skip to content

Conversation

@anhydrous99
Copy link

My attempt at fixing #524. This adds a fallback for when an image reference markdown is missing it's reference. As with links, the markdown is displayed.

This also adds two tests for this scenario, for images and links.

return {
_alt: capture[1] || undefined,
_fallbackContent: parse(
capture[0].replace(SQUARE_BRACKETS_R, '\\$1'),

Check failure

Code scanning / CodeQL

Incomplete string escaping or encoding

This does not escape backslash characters in the input.
@quantizor
Copy link
Owner

Simpler fix in #554, thank you for reporting!

@quantizor quantizor closed this Mar 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants