From abebf608617812b3dee3119b57f484a4bba06adc Mon Sep 17 00:00:00 2001 From: Luc Didry Date: Wed, 19 Jul 2017 20:26:26 +0200 Subject: [PATCH] respond_to correction --- lib/Lufi/Controller/Files.pm | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/lib/Lufi/Controller/Files.pm b/lib/Lufi/Controller/Files.pm index db3f723..7a783a8 100644 --- a/lib/Lufi/Controller/Files.pm +++ b/lib/Lufi/Controller/Files.pm @@ -392,8 +392,10 @@ sub delete { } return $c->respond_to( json => { - success => true, - msg => $msg + json => { + success => true, + msg => $msg + } }, any => sub { $c->render( @@ -407,8 +409,10 @@ sub delete { my $msg = $c->l('Could not find the file. Are you sure of the URL and the token?'); return $c->respond_to( json => { - success => false, - msg => $msg + json => { + success => false, + msg => $msg + } }, any => sub { $c->render( @@ -423,8 +427,10 @@ sub delete { my $msg = $c->l('Could not delete the file. You are not authenticated.'); return $c->respond_to( json => { - success => false, - msg => $msg + json => { + success => false, + msg => $msg + } }, any => sub { $c->render(