[freeside-commits] branch master updated. cace897d9c5fbe1f80277b0cb14e85c9d2272cf1

Ivan ivan at 420.am
Mon Oct 5 14:43:09 PDT 2015


The branch, master has been updated
       via  cace897d9c5fbe1f80277b0cb14e85c9d2272cf1 (commit)
       via  d942f94119fdc54dc416e309f36d385652fb5272 (commit)
      from  323d6a0c3ee3d7752225b712f5bdcfbb1581d61f (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit cace897d9c5fbe1f80277b0cb14e85c9d2272cf1
Merge: d942f94 323d6a0
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Mon Oct 5 14:43:05 2015 -0700

    Merge branch 'master' of git.freeside.biz:/home/git/freeside


commit d942f94119fdc54dc416e309f36d385652fb5272
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Mon Oct 5 14:42:57 2015 -0700

    fix UTF-8 in ClientAPI, RT#38254

diff --git a/FS/FS/ClientAPI_XMLRPC.pm b/FS/FS/ClientAPI_XMLRPC.pm
index 435ee98..dbcb565 100644
--- a/FS/FS/ClientAPI_XMLRPC.pm
+++ b/FS/FS/ClientAPI_XMLRPC.pm
@@ -30,6 +30,7 @@ L<FS::SelfService::XMLRPC>, L<FS::SelfService>
 use strict;
 
 use vars qw($DEBUG $AUTOLOAD);
+use Encode;
 use FS::XMLRPC_Lite; #XMLRPC::Lite, for XMLRPC::Data
 use FS::ClientAPI;
 
@@ -67,12 +68,17 @@ sub AUTOLOAD {
 
     shift; #discard package name;
 
+
     #$call = "FS::SelfService::$call";
     #no strict 'refs';
     #&{$call}(@_);
     #FS::ClientAPI->dispatch($autoload->{$call}, @_);
 
-    my $return = FS::ClientAPI->dispatch($autoload->{$call}, { @_ } );
+    my %hash = @_;
+    #XXX doesn't handle multi-level data structs
+    $hash{$_} = decode(utf8=>$hash{$_}) foreach keys %hash;
+
+    my $return = FS::ClientAPI->dispatch($autoload->{$call}, \%hash );
 
     if ( exists($typefix{$call}) ) {
       my $typefix = $typefix{$call};
@@ -85,7 +91,7 @@ sub AUTOLOAD {
 
     $return;
 
-  }else{
+  } else {
     die "No such procedure: $call";
   }
 }

-----------------------------------------------------------------------

Summary of changes:
 FS/FS/ClientAPI_XMLRPC.pm |   10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)




More information about the freeside-commits mailing list