]> git.joonet.de Git - adminer.git/commitdiff
Don't add the same page to history in AJAX
authorJakub Vrana <jakub@vrana.cz>
Fri, 11 Mar 2011 23:16:56 +0000 (00:16 +0100)
committerJakub Vrana <jakub@vrana.cz>
Fri, 11 Mar 2011 23:16:56 +0000 (00:16 +0100)
adminer/static/functions.js

index 7009c7f448aec5b9987053d7615d8ef46c671526..dae001c46d38f07d4aca95ee524b8df01a288d17 100644 (file)
@@ -301,7 +301,9 @@ function ajaxSend(url, data, popState) {
                                setHtml('loader', '');
                        } else {
                                if (!popState) {
-                                       history.pushState(data, '', url);
+                                       if (data || url != location.href) {
+                                               history.pushState(data, '', url);
+                                       }
                                        scrollTo(0, 0);
                                }
                                setHtml('content', text);