Hi all, So far I'm using Mojolicious for my application. Right now I have many constrollers within many files. On top of each file before the first controller I have this line:
my $log = Mojo::Log->new(path => '../log/app.log', level => 'debug'); So I can call $log->level() from controllers. 1. Can I place $log definition somewhere in App.pm file (which contains startup {} sub) and use this $log instead of defining $log into each controller file? (Define global $log or something like this...) 2. Can I change log format for this $log? I have a helper which returns client info (ip, id, etc) so I want in to be in logs. I can call $log like this: $log->level($self->GetClient.'message'); But probably I could call just $log->level('message') and log formatter might do rest? -- You received this message because you are subscribed to the Google Groups "Mojolicious" group. To unsubscribe from this group and stop receiving emails from it, send an email to mojolicious+unsubscr...@googlegroups.com. To post to this group, send email to mojolicious@googlegroups.com. Visit this group at http://groups.google.com/group/mojolicious. For more options, visit https://groups.google.com/d/optout.