diff -r 768aa027e7cb -r e621317229f7 CrashTest.pl --- a/CrashTest.pl Wed Jun 25 00:16:17 2014 +0200 +++ b/CrashTest.pl Wed Jul 30 23:49:59 2014 +0200 @@ -31,7 +31,7 @@ app->attr(decode_queue => sub { my $self = shift; - eval "require $config->{DecodeQueue}->{Type}"; + eval "require $config->{DecodeQueue}->{Type}" or die "Loading module failed $@"; return $config->{DecodeQueue}->{Type}->new($config->{DecodeQueue}, $config->{Dumper}, app->storage); }); @@ -98,11 +98,19 @@ my ($uuid, $uuidstr); UUID::generate($uuid); UUID::unparse($uuid, $uuidstr); - my $pjson = $self->app->decode_queue->decode($file, \%paramshash, $uuidstr); + + $self->render_later(); - # reply - $self->render_text($pjson->{status}); + $self->app->decode_queue->decode($file, \%paramshash, $uuidstr, sub { + my $pjson = shift; + # reply + $self->render(text => $pjson->{status}); + } + ); + }; -app->secret('My secret passphrase here'); +app->secrets([ + 'My secret passphrase here' +]); app->start;