Skip to content

Commit 029b82a

Browse files
committed
Merge branch 'pr/1029' into devel
Fixes #1029
2 parents 9d507e9 + ff149fb commit 029b82a

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

CHANGES

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ NEXT
66
* 'dancer' script warns and die if trying to create
77
an app with the same name of an existing module.
88
(GH#1038, Racke)
9+
* In Dancer::Logger::Abstract, default host
10+
name to '-' if not available. (GH#1029, John Wittkoski)
911

1012
[ DOCUMENTATION ]
1113
* Improve the wording of the params() section in Dancer.

lib/Dancer/Logger/Abstract.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ sub format_message {
8989
my $chars_mapping = {
9090
h => sub {
9191
defined $r
92-
? $r->env->{'HTTP_X_REAL_IP'} || $r->env->{'REMOTE_ADDR'}
92+
? $r->env->{'HTTP_X_REAL_IP'} || $r->env->{'REMOTE_ADDR'} || '-'
9393
: '-';
9494
},
9595
t => sub { Encode::decode(setting('charset') || 'utf8',

0 commit comments

Comments
 (0)