Skip to content
Snippets Groups Projects
Commit 69aa136e authored by deuce's avatar deuce
Browse files

When polling auth, throw an error if it becomes invalid.

parent 3d33da29
No related branches found
No related tags found
No related merge requests found
...@@ -168,6 +168,8 @@ ACMEv2.prototype.poll_authorization = function(auth) ...@@ -168,6 +168,8 @@ ACMEv2.prototype.poll_authorization = function(auth)
for (var challenge in ret.challenges) { for (var challenge in ret.challenges) {
if (ret.challenges[challenge].status == 'valid') if (ret.challenges[challenge].status == 'valid')
return true; return true;
if (ret.challenges[challenge].status == 'invalid')
throw ("Authorization failed... "+auth);
} }
return false; return false;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment