Skip to content

Commit

Permalink
feat(deviations): fallback deviation if language info is missing (#1181)
Browse files Browse the repository at this point in the history
  • Loading branch information
lindtvedtsebastian authored Aug 24, 2023
1 parent 7fdab2a commit 17c729a
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ function Situation({
situation?.summary.find((summary) => summary.language === 'no')
?.value ??
situation?.description.find((desc) => desc.language === 'no')?.value ??
situation?.summary[0]?.value ??
situation?.description[0]?.value ??
null

if (!situationText) return null
Expand Down

0 comments on commit 17c729a

Please sign in to comment.