From ccfa2d516fda6411acc7d2f00083172969aaf1d4 Mon Sep 17 00:00:00 2001 From: Svein-Tore Griff With Date: Sun, 1 Nov 2015 00:30:45 +0100 Subject: [PATCH] Make sure we get answered statements in the result log --- js/h5p-x-api.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/h5p-x-api.js b/js/h5p-x-api.js index e287c1a..2b2e36a 100644 --- a/js/h5p-x-api.js +++ b/js/h5p-x-api.js @@ -96,7 +96,7 @@ H5P.EventDispatcher.prototype.setActivityStarted = function() { * @param {H5P.XAPIEvent} event */ H5P.xAPICompletedListener = function (event) { - if (event.getVerb() === 'completed' && !event.getVerifiedStatementValue(['context', 'contextActivities', 'parent'])) { + if ((event.getVerb() === 'completed' || event.getVerb() === 'answered') && !event.getVerifiedStatementValue(['context', 'contextActivities', 'parent'])) { var score = event.getScore(); var maxScore = event.getMaxScore(); var contentId = event.getVerifiedStatementValue(['object', 'definition', 'extensions', 'http://h5p.org/x-api/h5p-local-content-id']);