Skip to content

Commit 9f70443

Browse files
committed
Customize: Make sure that preview and return URLs are URLs.
Merge of [37527] to the 3.9 branch. git-svn-id: https://develop.svn.wordpress.org/branches/3.9@37777 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 025819f commit 9f70443

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/wp-admin/customize.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,10 @@
1717

1818
wp_reset_vars( array( 'url', 'return' ) );
1919
$url = urldecode( $url );
20+
$url = esc_url_raw( $url );
2021
$url = wp_validate_redirect( $url, home_url( '/' ) );
2122
if ( $return )
22-
$return = wp_validate_redirect( urldecode( $return ) );
23+
$return = wp_validate_redirect( esc_url_raw( urldecode( $return ) ) );
2324
if ( ! $return )
2425
$return = $url;
2526

0 commit comments

Comments
 (0)