diff --git a/RELEASE.md b/RELEASE.md index db2ee89..150b3546 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -1,3 +1,12 @@ +# v1.3.1 # + +- No new features + +## Bugfixes ## + +- Don't specify a domain when setting cookies. This allows 411 to work when the hostname doesn't match the site configuration. + + # v1.3.0 # - Support for ES5.0 diff --git a/phplib/411bootstrap.php b/phplib/411bootstrap.php index 4fbe5d9..1e68b08 100644 --- a/phplib/411bootstrap.php +++ b/phplib/411bootstrap.php @@ -20,7 +20,7 @@ date_default_timezone_set("UTC"); define('BASE_DIR', realpath(__DIR__ . '/..')); -define('VERSION', '1.3.0'); +define('VERSION', '1.3.1'); // Set up autoloader for our classes. spl_autoload_register(function($class) { diff --git a/phplib/Cookie.php b/phplib/Cookie.php index d2b1eb4..25d2738 100644 --- a/phplib/Cookie.php +++ b/phplib/Cookie.php @@ -98,14 +98,13 @@ public static function generate($data, $date) { */ public static function write() { $site = SiteFinder::getCurrent(); - $domain = explode(':', $site['host'])[0]; if(self::$write && self::$dirty && Auth::isCookie()) { $expiry = $_SERVER['REQUEST_TIME'] + self::COOKIE_LIFETIME; setcookie( self::COOKIE_KEY, self::generate(self::$cache, $_SERVER['REQUEST_TIME']), $expiry, - '/', $domain, + '/', '', false, true ); }