Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
.then(data => {
// Success
const entity = data.entities[id];
const claims = wdk.simplifyClaims(entity.claims);
const description = entity.descriptions.en.value;
const label = entity.labels.en.value;
next({
type: "SET_STATE_VALUE",
key: "placeInfo",
value: {
description,
label,
image: getWikiMediaImageUrl(_.get(claims, "P18[0]")),
phoneNumber: _.get(claims, "P1329[0]"),
website: _.get(claims, "P856[0]"),
address: _.get(claims, "P969[0]"),
wikidata: id
}
});
})