Bug 21317: Format long lists under Koha Team tab as columns
[koha.git] / Koha / Illrequest.pm
index 53e9ddc..99b97bd 100644 (file)
@@ -21,14 +21,16 @@ package Koha::Illrequest;
 use Modern::Perl;
 
 use Clone 'clone';
-use File::Basename qw/basename/;
+use File::Basename qw( basename );
+use Encode qw( encode );
+use Mail::Sendmail;
+use Try::Tiny;
+
 use Koha::Database;
 use Koha::Email;
 use Koha::Exceptions::Ill;
 use Koha::Illrequestattributes;
 use Koha::Patron;
-use Mail::Sendmail;
-use Try::Tiny;
 
 use base qw(Koha::Object);
 
@@ -476,8 +478,8 @@ Return a list of available backends.
 
 sub available_backends {
     my ( $self ) = @_;
-    my @backends = $self->_config->available_backends;
-    return \@backends;
+    my $backends = $self->_config->available_backends;
+    return $backends;
 }
 
 =head3 available_actions
@@ -1016,8 +1018,8 @@ sub TO_JSON {
             $object->{capabilities} = $self->capabilities;
         }
         # Augment the request response with library details if appropriate
-        if ( $embed->{branch} ) {
-            $object->{branch} = Koha::Libraries->find(
+        if ( $embed->{library} ) {
+            $object->{library} = Koha::Libraries->find(
                 $self->branchcode
             )->TO_JSON;
         }