Skip to content

Commit

Permalink
add fall back in case language not already in localStorage
Browse files Browse the repository at this point in the history
  • Loading branch information
sserrata committed Sep 5, 2024
1 parent ae26ab6 commit 433b233
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ function CodeSnippets({ postman, codeSamples }: Props) {
setSelectedSample: setSelectedSample,
}}
languageSet={mergedLangs}
defaultValue={defaultLang[0].language}
defaultValue={defaultLang[0]?.language ?? mergedLangs[0].language}
lazy
>
{mergedLangs.map((lang) => {
Expand Down

0 comments on commit 433b233

Please sign in to comment.