Make WordPress Core


Ignore:
Timestamp:
08/31/2016 06:06:34 AM (9 years ago)
Author:
dd32
Message:

HTTP: Accept non-string values in cookies, fixing a regression since 4.5.

Props swissspidy.
Merges [38430] to the 4.6 branch.
Fixes #37768.

Location:
branches/4.6
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/4.6

  • branches/4.6/src/wp-includes/class-http.php

    r38173 r38461  
    434434            if ( $value instanceof WP_Http_Cookie ) {
    435435                $cookie_jar[ $value->name ] = new Requests_Cookie( $value->name, $value->value, $value->get_attributes() );
    436             } elseif ( is_string( $value ) ) {
     436            } elseif ( is_scalar( $value ) ) {
    437437                $cookie_jar[ $name ] = new Requests_Cookie( $name, $value );
    438438            }
Note: See TracChangeset for help on using the changeset viewer.