mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-05-01 20:20:10 +00:00
fhem.pl: resolve %L in logfiles even if logdir is not set (Forum #108865)
git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@21333 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
d47296b8dc
commit
13b7405729
4
fhem.pl
4
fhem.pl
@ -3494,7 +3494,9 @@ ResolveDateWildcards($@)
|
||||
my ($f, @t) = @_;
|
||||
return $f if(!$f);
|
||||
return $f if($f !~ m/%/); # Be fast if there is no wildcard
|
||||
$f =~ s/%L/$attr{global}{logdir}/g if($attr{global}{logdir}); #log directory
|
||||
my $logdir = AttrVal("global","logdir",
|
||||
AttrVal("global","modpath","")."/log");
|
||||
$f =~ s/%L/$logdir/g;
|
||||
return strftime($f,@t);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user