From 4100f4c82ad9ad6e7e9f2918b7abb8fe1c825008 Mon Sep 17 00:00:00 2001 From: bru5 <45365769+bru5@users.noreply.github.com> Date: Fri, 20 Aug 2021 16:02:16 +0100 Subject: [PATCH] [KED-2731] Update deprecated hljs call --- src/components/metadata/metadata-code.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/metadata/metadata-code.js b/src/components/metadata/metadata-code.js index 97c74c1ce2..f6186807d7 100644 --- a/src/components/metadata/metadata-code.js +++ b/src/components/metadata/metadata-code.js @@ -24,7 +24,7 @@ export const MetaDataCode = ({ const highlighted = useMemo(() => { const detected = hljs.highlightAuto(value); const language = detected.language || detected.second_best.language; - return language ? hljs.highlight(language, value).value : value; + return language ? hljs.highlight(value, { language }).value : value; }, [value]); return (