mirror of
https://github.com/WordPress/WordPress.git
synced 2025-02-22 15:31:42 +01:00
WP_HTTP: Fix returning WP_Error's on too-many-redirects after r23603 See #23682
git-svn-id: http://core.svn.wordpress.org/trunk@23608 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
46a4d2d295
commit
d4b814df2f
@ -109,8 +109,9 @@ class WP_Http {
|
||||
$r = wp_parse_args( $args, $defaults );
|
||||
$r = apply_filters( 'http_request_args', $r, $url );
|
||||
|
||||
// Certain classes decrement this, store a copy of the original value for loop purposes.
|
||||
$r['_redirection'] = $r['redirection'];
|
||||
// The transports decrement this, store a copy of the original value for loop purposes.
|
||||
if ( ! isset( $r['_redirection'] ) )
|
||||
$r['_redirection'] = $r['redirection'];
|
||||
|
||||
// Allow plugins to short-circuit the request
|
||||
$pre = apply_filters( 'pre_http_request', false, $r, $url );
|
||||
|
Loading…
Reference in New Issue
Block a user