From 2e257832d224133d06ce95a984eaf2886c2d649b Mon Sep 17 00:00:00 2001 From: eadjei Date: Wed, 16 Aug 2017 18:33:35 +0100 Subject: [PATCH] append .local to domain in set_cookie this fixes [rt.cpan.org #105215] #24 --- lib/HTTP/Cookies.pm | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/HTTP/Cookies.pm b/lib/HTTP/Cookies.pm index e0a75d0d..5a452aa6 100644 --- a/lib/HTTP/Cookies.pm +++ b/lib/HTTP/Cookies.pm @@ -396,6 +396,7 @@ sub set_cookie $key, $val, $path, $domain, $port, $path_spec, $secure, $maxage, $discard, $rest) = @_; + $domain = "$domain.local" unless $domain =~ /\./; # path and key can not be empty (key can't start with '$') return $self if !defined($path) || $path !~ m,^/, || !defined($key) || $key =~ m,^\$,;