From fde9edd139b05abd7bc2de7e6e029ed902ef0de8 Mon Sep 17 00:00:00 2001 From: AJ ONeal Date: Fri, 4 May 2018 20:35:34 +0000 Subject: [PATCH] cleanup --- index.html | 10 ++++++++-- js/app.js | 2 +- js/bacme.js | 4 ++-- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/index.html b/index.html index 492ffbc..d0a2c4e 100644 --- a/index.html +++ b/index.html @@ -34,14 +34,20 @@


+

+

+
+ @@ -152,12 +158,12 @@

- +

- +
diff --git a/js/app.js b/js/app.js index 2fefb13..42eceea 100644 --- a/js/app.js +++ b/js/app.js @@ -72,7 +72,7 @@ if (a > b) { return -1; } }); - return BACME.directory($qs('.js-acme-directory-url').value).then(function (directory) { + return BACME.directory({ directoryUrl: $qs('.js-acme-directory-url').value }).then(function (directory) { $qs('.js-acme-tos-url').href = directory.meta.termsOfService; return BACME.nonce().then(function (_nonce) { nonce = _nonce; diff --git a/js/bacme.js b/js/bacme.js index 5673646..00e7c45 100644 --- a/js/bacme.js +++ b/js/bacme.js @@ -33,8 +33,8 @@ BACME._logBody = function (body) { console.log(''); }; -BACME.directory = function (url) { - return webFetch(directoryUrl, { mode: 'cors' }).then(function (resp) { +BACME.directory = function (opts) { + return webFetch(opts.directoryUrl || directoryUrl, { mode: 'cors' }).then(function (resp) { BACME._logHeaders(resp); return resp.json().then(function (body) { directory = body;