Skip to content
This repository has been archived by the owner on Apr 3, 2020. It is now read-only.

Commit

Permalink
Merge pull request #37 from minggangw/XWALK-6798
Browse files Browse the repository at this point in the history
[IAP]Throw an error when the options.channel is undefined
  • Loading branch information
Halton Huo committed Apr 26, 2016
2 parents 5d46447 + a5ac0c1 commit 4bdd0dd
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions iap/iap.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ exports.init = function(options) {
return new Promise(function(resolve, reject) {
if (g_initialized)
throw new DOMError("InvalidStateError");
if (typeof(options.channel) === "undefined")
throw new DOMError("InvalidAccessError");
var resolveWrapper = function() {
g_initialized = true;
resolve();
Expand Down

0 comments on commit 4bdd0dd

Please sign in to comment.