mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 22:30:04 +00:00
HTTP: Add support for the host-only flag to Wp_Http_Cookie.
Props soulseekah. Fixes #43231. git-svn-id: https://develop.svn.wordpress.org/trunk@45135 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -164,11 +164,12 @@ class WP_HTTP_Requests_Response extends WP_HTTP_Response {
|
||||
foreach ( $this->response->cookies as $cookie ) {
|
||||
$cookies[] = new WP_Http_Cookie(
|
||||
array(
|
||||
'name' => $cookie->name,
|
||||
'value' => urldecode( $cookie->value ),
|
||||
'expires' => isset( $cookie->attributes['expires'] ) ? $cookie->attributes['expires'] : null,
|
||||
'path' => isset( $cookie->attributes['path'] ) ? $cookie->attributes['path'] : null,
|
||||
'domain' => isset( $cookie->attributes['domain'] ) ? $cookie->attributes['domain'] : null,
|
||||
'name' => $cookie->name,
|
||||
'value' => urldecode( $cookie->value ),
|
||||
'expires' => isset( $cookie->attributes['expires'] ) ? $cookie->attributes['expires'] : null,
|
||||
'path' => isset( $cookie->attributes['path'] ) ? $cookie->attributes['path'] : null,
|
||||
'domain' => isset( $cookie->attributes['domain'] ) ? $cookie->attributes['domain'] : null,
|
||||
'host_only' => isset( $cookie->flags['host-only'] ) ? $cookie->flags['host-only'] : null,
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user