componentsjs 5.4.0 → 5.4.1

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.
@@ -17,14 +17,13 @@ class ArgumentConstructorHandlerHash {
17
17
  if (!entry.property.key) {
18
18
  throw new ErrorResourcesContext_1.ErrorResourcesContext(`Missing key in fields entry`, { entry, argument });
19
19
  }
20
- const key = await argsCreator.getArgumentValues(entry.properties.key, settings);
21
- if (typeof key !== 'string') {
22
- throw new ErrorResourcesContext_1.ErrorResourcesContext(`Illegal non-string key (${entry.property.key.value} as ${entry.property.key.type}) in fields entry`, { entry, argument });
20
+ if (entry.property.key.type !== 'Literal') {
21
+ throw new ErrorResourcesContext_1.ErrorResourcesContext(`Illegal non-literal key (${entry.property.key.value} as ${entry.property.key.type}) in fields entry`, { entry, argument });
23
22
  }
24
23
  // Recursively get value arg value
25
24
  if (entry.property.value) {
26
25
  const subValue = await argsCreator.getArgumentValues(entry.properties.value, settings);
27
- return { key, value: subValue };
26
+ return { key: entry.property.key.value, value: subValue };
28
27
  }
29
28
  // Ignore cases where value may not be set, because params may be optional
30
29
  }));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "componentsjs",
3
- "version": "5.4.0",
3
+ "version": "5.4.1",
4
4
  "description": "A semantic dependency injection framework",
5
5
  "lsd:contexts": {
6
6
  "https://linkedsoftwaredependencies.org/bundles/npm/componentsjs/^5.0.0/components/context.jsonld": "components/context.jsonld"