From 83b05dc62c5713d2103b41ccc0598dfbf890fd83 Mon Sep 17 00:00:00 2001
From: Katrin Silvius <katrinsilvius@gmail.com>
Date: Mon, 28 Feb 2011 10:06:03 -0800
Subject: [PATCH] Allow passing objects without casting them to arrays

---
 lib/drupal_soap_client.inc |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/lib/drupal_soap_client.inc b/lib/drupal_soap_client.inc
index 1683210..caef3a6 100644
--- a/lib/drupal_soap_client.inc
+++ b/lib/drupal_soap_client.inc
@@ -48,7 +48,9 @@ class DrupalSoapClient {
       return $result;
     }
     
-    $params = (array) $params;
+    if (!is_object($params)) {
+      $params = (array) $params;
+    }
 
     if ( $this->client == NULL ) {
       $result['#error'] = t('SOAP client object is not initialised');
-- 
1.7.3.5

