scorm-again 2.6.0 → 2.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/scorm12.js CHANGED
@@ -729,6 +729,11 @@ var BaseAPI = (function () {
729
729
  };
730
730
  BaseAPI.prototype.loadFromJSON = function (json, CMIElement) {
731
731
  if (CMIElement === void 0) { CMIElement = ""; }
732
+ if ((!CMIElement || CMIElement === "") &&
733
+ !Object.hasOwnProperty.call(json, "cmi") &&
734
+ !Object.hasOwnProperty.call(json, "adl")) {
735
+ CMIElement = "cmi";
736
+ }
732
737
  if (!this.isNotInitialized()) {
733
738
  console.error("loadFromJSON can only be called before the call to lmsInitialize.");
734
739
  return;
@@ -3472,7 +3477,7 @@ function __disposeResources(env) {
3472
3477
  var __webpack_exports__ = {};
3473
3478
  __webpack_require__.r(__webpack_exports__);
3474
3479
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
3475
- /* harmony export */ Scorm12Impl: function() { return /* binding */ Scorm12Impl; }
3480
+ /* harmony export */ Scorm12API: function() { return /* binding */ Scorm12Impl; }
3476
3481
  /* harmony export */ });
3477
3482
  /* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(635);
3478
3483
  /* harmony import */ var _cmi_scorm12_cmi__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(989);
@@ -3770,7 +3775,7 @@ var Scorm12Impl = (function (_super) {
3770
3775
  }(_BaseAPI__WEBPACK_IMPORTED_MODULE_8__["default"]));
3771
3776
 
3772
3777
 
3773
- var __webpack_export_target__ = this;
3778
+ var __webpack_export_target__ = window;
3774
3779
  for(var __webpack_i__ in __webpack_exports__) __webpack_export_target__[__webpack_i__] = __webpack_exports__[__webpack_i__];
3775
3780
  if(__webpack_exports__.__esModule) Object.defineProperty(__webpack_export_target__, "__esModule", { value: true });
3776
3781
  /******/ })()