Merge pull request #2744 from Gared/switchtopadBroken

Fix broken switchToPad method
pull/2749/head
Stefan 2015-08-05 18:39:37 +02:00
commit a0ca051801
1 changed files with 2 additions and 2 deletions

View File

@ -465,8 +465,8 @@ var pad = {
},
switchToPad: function(padId)
{
var newHref = new RegExp(/.*\/p\/[^\/]+/).exec(document.location.pathname) || clientVars.padId;
newHref = newHref[0];
var options = document.location.href.split('?')[1];
var newHref = padId;
if (typeof options != "undefined" && options != null){
newHref = newHref + '?' + options;
}