Skip to content

fix(visualize): return empty on extract_code_block language miss - #685

Open
santhreal wants to merge 6 commits into
HKUDS:devfrom
santhreal:fix/extract-code-block-lang-miss
Open

fix(visualize): return empty on extract_code_block language miss#685
santhreal wants to merge 6 commits into
HKUDS:devfrom
santhreal:fix/extract-code-block-lang-miss

Conversation

@santhreal

Copy link
Copy Markdown
Contributor

extract_code_block returned the full text when the language hint did not match, so callers that fall back with or never ran their unhinted path for fences like ```json when asking for javascript.

Return an empty string on a language miss so the usual fallback can extract the fence.

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.

1 participant