]> git.wh0rd.org Git - tt-rss.git/commitdiff
api: openExternalUrl(); more checks in all_counters_callback
authorAndrew Dolgov <fox@bah.spb.su>
Sun, 27 Nov 2005 19:29:44 +0000 (20:29 +0100)
committerAndrew Dolgov <fox@bah.spb.su>
Sun, 27 Nov 2005 19:29:44 +0000 (20:29 +0100)
functions.js

index d3886437b932bc391657c56d50b5b52e09208e8b..3aef7befafbdb446c96da512c533247abdf981b5 100644 (file)
@@ -343,7 +343,7 @@ if (!xmlhttp_rpc && typeof XMLHttpRequest!='undefined') {
 function all_counters_callback() {
        if (xmlhttp_rpc.readyState == 4) {
                try {
-                       if (!xmlhttp_rpc.responseXML) {
+                       if (!xmlhttp_rpc.responseXML || !xmlhttp_rpc.responseXML.firstChild) {
                                notify("[all_counters_callback] backend did not return valid XML");
                                return;
                        }
@@ -541,4 +541,7 @@ function toggleSelectRow(sender) {
        }
 }
 
+function openExternalUrl(url) {
+       var w = window.open(url);
+}