Skip to content

Commit 19cc86e

Browse files
committed
Don't fail when language is missing from metadata context
Assume en-ys
1 parent 848f8dd commit 19cc86e

File tree

1 file changed

+1
-1
lines changed
  • cardano-db-sync/src/Cardano/DbSync/OffChain/Vote

1 file changed

+1
-1
lines changed

cardano-db-sync/src/Cardano/DbSync/OffChain/Vote/Types.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ instance FromJSON Context where
365365
parseJSON =
366366
withObject "Context" $ \o ->
367367
Context
368-
<$> o .: "@language"
368+
<$> o .:? "@language" .!= "en-us"
369369

370370
instance FromJSON TextValue where
371371
parseJSON v = case v of

0 commit comments

Comments
 (0)