HTTP API: Use WP_HTTP_Response::set_data()
in ::__construct()
instead of directly accessing the $data
property.
Props tfrommen. Fixes #41759. git-svn-id: https://develop.svn.wordpress.org/trunk@41707 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
fb06fab2e8
commit
fac51f61e3
@ -48,7 +48,7 @@ class WP_HTTP_Response {
|
||||
* @param array $headers Optional. HTTP header map. Default empty array.
|
||||
*/
|
||||
public function __construct( $data = null, $status = 200, $headers = array() ) {
|
||||
$this->data = $data;
|
||||
$this->set_data( $data );
|
||||
$this->set_status( $status );
|
||||
$this->set_headers( $headers );
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user