epic-ts
[kivitendo-erp.git] / SL / Template / Plugin / JSON.pm
index 3709d8f..0586511 100644 (file)
@@ -1,5 +1,6 @@
 package SL::Template::Plugin::JSON;
 
+use strict;
 use JSON ();
 use Carp qw(croak);
 use base qw(Template::Plugin);
@@ -20,7 +21,7 @@ sub json_converter {
   my ($self, %params) = @_;
 
   if (!$self->{json}) {
-    $self->{json} = JSON->new->allow_nonref(1);
+    $self->{json} = JSON->new->allow_nonref(1)->convert_blessed(1);
 
     my $args = $self->{json_args};