diff --git a/src/Illuminate/Cookie/CookieJar.php b/src/Illuminate/Cookie/CookieJar.php index 4f5380982b49..45f15f70e0ff 100755 --- a/src/Illuminate/Cookie/CookieJar.php +++ b/src/Illuminate/Cookie/CookieJar.php @@ -161,7 +161,7 @@ public function queue(...$parameters) * @param string|null $domain * @return void */ - public function queueForget($name, $path = null, $domain = null) + public function expire($name, $path = null, $domain = null) { $this->queue($this->forget($name, $path, $domain)); } diff --git a/tests/Cookie/CookieTest.php b/tests/Cookie/CookieTest.php index 90e23bd041e3..5f5a3f906f67 100755 --- a/tests/Cookie/CookieTest.php +++ b/tests/Cookie/CookieTest.php @@ -118,12 +118,12 @@ public function testHasQueuedWithPath(): void $this->assertFalse($cookieJar->hasQueued('foo', '/wrongPath')); } - public function testQueueForget() + public function testExpire() { $cookieJar = $this->getCreator(); $this->assertCount(0, $cookieJar->getQueuedCookies()); - $cookieJar->queueForget('foobar', '/path', '/domain'); + $cookieJar->expire('foobar', '/path', '/domain'); $cookie = $cookieJar->queued('foobar'); $this->assertEquals('foobar', $cookie->getName());