diff --git a/ajax-requests/js/jsonCap.js b/ajax-requests/js/jsonCap.js index d9f4e1a..0d82fb7 100644 --- a/ajax-requests/js/jsonCap.js +++ b/ajax-requests/js/jsonCap.js @@ -26,6 +26,8 @@ function captureJSON() { } else { console.log('Connection to Server succeeded. Content was not received due to error.'); } + } else { + btnTxt = btnTxt.replace('hide', 'capture'); } div.innerHTML = content; btn.textContent = btnTxt;