You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
var e = data.entities.Q19180293
wdk.simplify.qualifiers(e.claims.P1433[0].qualifiers.P156[0])
TypeError: Cannot destructure property `value` of 'undefined' or 'null'.
at Object.simplifyClaim (/<...>/node_modules/wikidata-sdk/lib/helpers/simplify_claims.js:96:17)
at parse (/<...>/node_modules/wikidata-sdk/lib/helpers/parse_claim.js:84:31)
at Object.entity (/<...>/node_modules/wikidata-sdk/lib/helpers/parse_claim.js:9:40)
at prefixedId (/<...>/node_modules/wikidata-sdk/lib/helpers/parse_claim.js:18:21)
Which means of course that following functions all crash too:
Setting somevalueValue and novalueValue doesn't help.
P.S. The naming for the simplify.qualifier and simplify.qualifiers functions is a little confusing, as if they're swapped. But they are documented correctly. Was this intentional?
The text was updated successfully, but these errors were encountered:
I think the naming swap should be considered a breaking change and probably requires a major version bump though, even if it was technically a mistake in the first place. I've also opened a tiny PR for the docs: #48
Real examples:
Which means of course that following functions all crash too:
Setting
somevalueValue
andnovalueValue
doesn't help.P.S. The naming for the
simplify.qualifier
andsimplify.qualifiers
functions is a little confusing, as if they're swapped. But they are documented correctly. Was this intentional?The text was updated successfully, but these errors were encountered: