Advertisement
Guest User

Untitled

a guest
Jul 10th, 2014
13
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Perl 0.69 KB | None | 0 0
  1.     $self->hook(before_render => sub {
  2.         my ($c, $args) = @_;
  3.         if ($args->{'exception'}) {
  4.             $log->debug('Path '.$c->tx->req->url->path);
  5.             $log->debug('IP: '.$c->tx->req->content->headers->{'headers'}->{'x-forwarded-for'}->[0]);
  6.             $log->debug('User Name: '.$c->{'stash'}->{'__authentication__'}->{'user'}->{'name'});
  7.             $log->debug('User id: '.$c->{'stash'}->{'__authentication__'}->{'user'}->{'id'});
  8.             $log->debug('Frame: '.$args->{'exception'}->{'frames'}->[0]->[1]);
  9.             $log->debug('Line Num: '.$args->{'exception'}->{'line'}->[0]);
  10.             $log->debug('Line Text: '.$args->{'exception'}->{'line'}->[1]);
  11.             $log->debug('Message: '.$args->{'exception'}->{'message'});
  12.             return;
  13.         }
  14.         });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement