This allows the subsequent redirect to behave as expected if a site is using a strict referrer policy on the front end which prevents the full referrer from being sent.
Props zodiac1978, yogeshbhutkar, hbhalodia, mukesh27.
Fixes#62881
Built from https://develop.svn.wordpress.org/trunk@59753
git-svn-id: http://core.svn.wordpress.org/trunk@59095 1a063a9b-81f0-0310-95a4-ce76da25c4cd