Skip to content

Commit 7d75105

Browse files
authored
Merge pull request #19 from 17e/hash-req
Fix the set_favicon sub
2 parents e07559d + 4c49a65 commit 7d75105

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/AnyEvent/HTTP/Server.pm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -113,8 +113,8 @@ sub DESTROY { $_[0]->destroy };
113113

114114
sub set_favicon {
115115
my $self = shift;
116-
if (shift) {
117-
my $icondata = shift;
116+
my $icondata = shift;
117+
if ($icondata) {
118118
$self->{ico} = "HTTP/1.1 200 OK${LF}Connection:close${LF}Content-Type:image/x-icon${LF}Content-Length:".length($icondata)."${LF}${LF}".$icondata;
119119
}
120120
else {

0 commit comments

Comments
 (0)