Skip to content

Commit 6ab0f0f

Browse files
committed
track the URL queried
1 parent 6823f15 commit 6ab0f0f

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

assets/client.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -272,10 +272,14 @@ function showSpinner(msg) {
272272
div.appendChild(msgDiv);
273273
}
274274

275+
let lastQueriedURL = null;
276+
275277
// disable the user interface, initiate an XHR
276278
function sendQuery(url, followReferral=false, followingReferral=true) {
277279
freezeUI();
278280

281+
lastQueriedURL = null;
282+
279283
if (0 == url.indexOf('json://')) {
280284
// run the callback with a mock XHR
281285
handleResponse({
@@ -342,6 +346,8 @@ function createErrorNode(error) {
342346
function handleResponse(xhr, followReferral=false) {
343347
thawUI();
344348

349+
lastQueriedURL = xhr.responseURL;
350+
345351
if (404 == xhr.status) {
346352
handleError('This object does not exist.');
347353

0 commit comments

Comments
 (0)