webtrees
webtrees copied to clipboard
Redirected list branches from old url adds 'x' in front of surname
Spotted an issue after my long overdue migration. When an old url to a list of branches gets redirected, an 'x' is put at the front of the surname.
Analysis:
when getting the old url /branches.php?ged=MyTree&surname=Doe
it redirects to /module/branches_list/Page/MyTree?soundex_dm=&soundex_std=&surname=Doe
which in turn redirects to /tree/MyTree/branches/xDoe?soundex_dm=0&soundex_std=0
I found the issue is in function getPageAction of /app/Module/BranchesListModule.php :
'surname' => 'x' . Validator::queryParams($request)->string('surname'),
I'm preparing a PR to fix this myself
Here's the PR with a fix: https://github.com/fisharebest/webtrees/pull/5020
I have verified that an old url without a name eg /branches.php?ged=MyTree eventually redirects to /tree/MyTree/branches?soundex_dm=0&soundex_std=0
Closed by #5020