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
Sorry for the short description but it took me quite some times already to find the issue. Then reading the code it normal that the potential array is not a function.
Context query with contains condition on a string set, it calls toDyamo with set modifier on the field, and it fails cause it get an array and this is not callable.
There is Array.isArray above with array.some but then consider it as a function only a few line down.
And this called by:
// This function returns the DynamoDB property name for a given attribute (alias or property name). For example if you have a `pk` with an alias of `userID` and pass in `userID` it will return `pk`. If you pass in `pk` it will return `pk`.
"dynamoPropertyForAttribute": async (attribute) => {
const obj = await Item.objectFromSchema({ [attribute]: true }, this, { "type": "toDynamo", "modifiers": ["set"], "typeCheck": false, "mapAttributes": true });
return Object.keys(obj)[0];
},
I'm not so sure why the set modifier need to be called here specially if the attribute is set to true, this does not really work, is it?
The text was updated successfully, but these errors were encountered:
Sorry for the short description but it took me quite some times already to find the issue. Then reading the code it normal that the potential array is not a function.
Context query with contains condition on a string set, it calls toDyamo with set modifier on the field, and it fails cause it get an array and this is not callable.
There is Array.isArray above with array.some but then consider it as a function only a few line down.
And this called by:
I'm not so sure why the set modifier need to be called here specially if the attribute is set to true, this does not really work, is it?
The text was updated successfully, but these errors were encountered: