@sis-cc/dotstatsuite-components 13.5.2 → 13.5.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -16,7 +16,9 @@ var getMetadataCoordinates = exports.getMetadataCoordinates = function getMetada
16
16
  var annotations = R.pathOr([], ['data', 'structure', 'annotations'], sdmxJson);
17
17
  var metadataAvailKeys = R.pipe(R.pathOr([], ['data', 'dataSets', 0, 'dimensionGroupAttributes']), R.map(function (indexes) {
18
18
  return R.props(indexes, annotations);
19
- }), R.filter(R.find(R.propEq('type', 'HAS_METADATA'))), R.keys)(sdmxJson);
19
+ }), R.filter(R.find(function (a) {
20
+ return a && R.propEq('type', 'HAS_METADATA', a);
21
+ })), R.keys)(sdmxJson);
20
22
 
21
23
  return R.map(function (key) {
22
24
  var indexes = R.split(':', key);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@sis-cc/dotstatsuite-components",
3
3
  "description": "Set components based on React.",
4
- "version": "13.5.2",
4
+ "version": "13.5.3",
5
5
  "main": "lib/index.js",
6
6
  "author": "OECD",
7
7
  "license": "MIT",
@@ -6,7 +6,7 @@ export const getMetadataCoordinates = (sdmxJson) => {
6
6
  const metadataAvailKeys = R.pipe(
7
7
  R.pathOr([], ['data', 'dataSets', 0, 'dimensionGroupAttributes']),
8
8
  R.map(indexes => R.props(indexes, annotations)),
9
- R.filter(R.find(R.propEq('type', 'HAS_METADATA'))),
9
+ R.filter(R.find(a => a && R.propEq('type', 'HAS_METADATA', a))),
10
10
  R.keys
11
11
  )(sdmxJson);
12
12