Problems with xAPI change to Fill in the Blanks

I have some custom javascript that is supposed to be triggered on Fill in the Blanks questions (consisting of several blanks) when the user checks the answer. Previously, using the getScore method like this worked: if(event.getScore() != null){

After updating to the latest H5P libraries, however, that method no longer works because a score is now being generated by the xAPI event statement (and "completion" is even being set to "true") as soon as the user enters any text into any of the blanks. It does not really make sense to me why the event statement would be generating a statement providing a score and showing "completion" as true just as soon as the user begins interacting with the content.

Is this a bug in the xAPI statement or was this change intentionally made for some other reason? If it's the latter, then is there anything else in the event statement now that I can listen for to indicate the user has hit the "Check" button? This functionality is vital to how I'm using this content type on my site.

falcon's picture

This is a bug. Will be fixed shortly. Thank you for reporting it!

Thanks. I just saw commit fix on GitHub for this and applied it to my library. It works! All is well with my fill-in-the-blank questions now. Thanks for the quick fix! :)

falcon's picture

Yes, thank you for reporting it. It isn't a problem that users sees, but can break many integrations.

icc's picture

The version available on h5p.org should be updated with a fix now.