[Nagvis-checkins] SF.net Git: nagvis: Bugfix: Fixed javascript error when switching pages while an
Brought to you by:
larsi-
From: lars <la...@us...> - 2012-03-29 09:01:08
|
Author: Lars Michelsen <lm...@la...> Date: Thu Mar 29 11:00:31 2012 +0200 Committer: Lars Michelsen <lm...@la...> Commit-Date: Thu Mar 29 11:00:52 2012 +0200 Bugfix: Fixed javascript error when switching pages while an ajax call is being processed --- ChangeLog | 2 ++ share/frontend/nagvis-js/js/ajax.js | 2 +- 2 files changed, 3 insertions(+), 1 deletions(-) diff --git a/ChangeLog b/ChangeLog index b55e073..4f75b57 100644 --- a/ChangeLog +++ b/ChangeLog @@ -24,6 +24,8 @@ Frontend * Bugfix: Fixed cloning shape objects (view_type error message) * Bugfix: Stateless lines - only showing the hover area when it is needed * Bugfix: Fixed dragging of relative labels of relative objects + * Bugfix: Fixed javascript error when switching pages while an ajax call is + being processed 1.6.4 Core diff --git a/share/frontend/nagvis-js/js/ajax.js b/share/frontend/nagvis-js/js/ajax.js index 4b426e2..cc19964 100644 --- a/share/frontend/nagvis-js/js/ajax.js +++ b/share/frontend/nagvis-js/js/ajax.js @@ -171,7 +171,7 @@ function getAsyncRequest(sUrl, bCacheable, callback, callbackParams) { oRequest.open("GET", sUrl+"&_t="+iNow); oRequest.setRequestHeader("If-Modified-Since", "Sat, 1 Jan 2005 00:00:00 GMT"); oRequest.onreadystatechange = function() { - if(oRequest.readyState == 4) { + if(oRequest && oRequest.readyState == 4) { frontendMessageRemove('ajaxError'); if(oRequest.responseText.replace(/\s+/g, '').length === 0) { if(bCacheable) |