Skip to content

Commit

Permalink
Merge pull request #69 from oat-sa/hotfix/NCSUP-268/external-logs
Browse files Browse the repository at this point in the history
Hotfix/ncsup 268/external logs
  • Loading branch information
Aleh Hutnikau authored Apr 24, 2020
2 parents ad28b5e + 814c35d commit a16f1a2
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@oat-sa/tao-item-runner-qti",
"version": "0.4.18",
"version": "0.4.18-1",
"displayName": "TAO Item Runner QTI",
"description": "TAO QTI Item Runner modules",
"files": [
Expand Down
9 changes: 7 additions & 2 deletions src/qtiItem/core/Loader.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ import qtiClasses from 'taoQtiItem/qtiItem/core/qtiClasses';
import Element from 'taoQtiItem/qtiItem/core/Element';
import xmlNsHandler from 'taoQtiItem/qtiItem/helper/xmlNsHandler';
import moduleLoader from 'core/moduleLoader';
import loggerFactory from 'core/logger';

var logger = loggerFactory('taoQtiItem/qtiItem/core/Loader');

var Loader = Class.extend({
init: function(item, classesLocation) {
Expand Down Expand Up @@ -54,7 +57,8 @@ var Loader = Class.extend({
var i;
var requiredClass,
requiredClasses = this.getRequiredClasses(data, reload),
required = [];
required = [],
callStack;

for (i in requiredClasses) {
requiredClass = requiredClasses[i];
Expand All @@ -64,7 +68,8 @@ var Loader = Class.extend({
category: 'qti'
});
} else {
throw new Error('missing qti class location declaration : ' + requiredClass);
callStack = new Error().stack;
logger.error({requiredClasses, data, callStack}, 'Missing qti class location declaration:');
}
}

Expand Down

0 comments on commit a16f1a2

Please sign in to comment.