Open aemion-docebo opened 2 years ago
Sorry but the above issue raised is WRONG. The specification clearly states that the contextActivities entries (grouping, parent) must always be an array, even if the array only contains only a single activity. The validator checking for the array case only is correct.
Hello,
As per the specification: https://github.com/adlnet/xAPI-Spec/blob/master/xAPI-Data.md#requirements-11, the values in the contextActivities object (grouping, parent, etc...) can be a single Activity object or an array of Activity objects. From what I've seen, the library is only validating the array case making it non xAPI compliant.
Is it ok to change this behaviour to accept both cases? If yes, I can work on a Pull Request.