Index: services.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/services/Attic/services.module,v
retrieving revision 1.8.2.9
diff -u -r1.8.2.9 services.module
--- services.module	8 May 2008 00:24:53 -0000	1.8.2.9
+++ services.module	5 Jul 2008 16:45:16 -0000
@@ -105,10 +105,10 @@
   // method
   $items['admin/build/services/browse/%services_method'] = array(
     'title' => 'Services',
-  	'description' => 'Calls a Services method.',
+    'description' => 'Calls a Services method.',
     'page callback' => 'services_admin_browse_method',
     'page arguments' => array(4),
-  	'access arguments' => array('administer services'),
+    'access arguments' => array('administer services'),
     'type' => MENU_LOCAL_TASK,
     'file' => 'services_admin_browse.inc',
   );
@@ -125,7 +125,7 @@
     'title' => 'Services',
     'access arguments' => array('access services'),
     'page callback' => 'services_server',
-  	'page arguments' => array(1),
+    'page arguments' => array(1),
     'type' => MENU_CALLBACK,
   );
   
@@ -249,14 +249,14 @@
   // Add additonal processing for methods requiring api key
   if (variable_get('services_use_key', TRUE)) {
     $api_key = array_shift($args);
-    $domain = null;
     $timestamp = null;
     $hash =  null;
+    $domain = null;
     // Check strict domain matching.
     if (variable_get('services_domain_strict', false)) {
-      $domain = array_shift($args);
       $timestamp = array_shift($args);
-      $hash = $api_key;
+      $hash = array_shift($args);
+      $domain = $api_key;
       $api_key = db_result(db_query("SELECT kid FROM {services_keys} WHERE domain = '%s'", $domain));
     }
     if (!services_validate_key($api_key, $timestamp, $domain, $hash)) {
@@ -422,13 +422,13 @@
     }
   }
   else{
-  	$rehash = md5($kid . $timestamp . $domain);
-  	if($rehash == $hash){
-  	  return true;
-  	}
-  	else{
-  	  return false;
-  	}
+    $rehash = md5($kid . $timestamp . $domain);
+    if($rehash == $hash){
+      return true;
+    }
+    else{
+     return false;
+    }
   }    
 }
 
@@ -542,5 +542,4 @@
   // Revert to previous user and session data
   $user = $backup;
   session_decode($user->session);
-}
-
+}
\ No newline at end of file

