From ee75f0e92d0e7b20b10da34631ad03e6511d1620 Mon Sep 17 00:00:00 2001 From: Eric Riggs Date: Wed, 7 Mar 2018 17:01:09 -0400 Subject: [PATCH] Prevent default when opening a link in a new window. Fixes Swagger page opening twice. Signed-off-by: Eric Riggs --- mayan/apps/appearance/static/appearance/js/mayan_app.js | 1 + 1 file changed, 1 insertion(+) diff --git a/mayan/apps/appearance/static/appearance/js/mayan_app.js b/mayan/apps/appearance/static/appearance/js/mayan_app.js index 2238e5fec8..6a1636de50 100644 --- a/mayan/apps/appearance/static/appearance/js/mayan_app.js +++ b/mayan/apps/appearance/static/appearance/js/mayan_app.js @@ -157,6 +157,7 @@ App.prototype.setupAutoSubmit = function () { App.prototype.setupNewWindowAnchor = function () { $('a.new_window').click(function (event) { + event.preventDefault(); var newWindow = window.open($(this).attr('href'), '_blank'); newWindow.focus(); });