Index: mobile_tools.module
===================================================================
--- mobile_tools.module	(.../trunk/htdocs/sites/all/modules/contrib/mobile_tools/mobile_tools.module)	(revision 12715)
+++ mobile_tools.module	(.../branches/contest/sites/all/modules/contrib/mobile_tools/mobile_tools.module)	(revision 13353)
@@ -178,8 +178,8 @@
   $page_match = FALSE;
   if(isset($_GET['q']) && $pages != '') {
     //check if there is no exception in the redirect path (code comes from block.module)
-    include_once './includes/bootstrap.inc';
-    drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
+    drupal_bootstrap(DRUPAL_BOOTSTRAP_PATH);
+
     $path = drupal_get_path_alias($_GET['q']);
     // Compare with the internal and path alias (if any).
     $page_match = drupal_match_path($path, $pages);
@@ -200,8 +200,10 @@
     // The case where a desktop user is accessing the mobile site 
     } 
     elseif ($device['type'] == 'desktop' && $current_url_type == 'mobile') {
-       $destination =  variable_get('mobile_tools_desktop_url', $base_url);
-       mobile_tools_goto($destination);
+      include_once './includes/bootstrap.inc';
+      drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);      
+      $destination =  variable_get('mobile_tools_desktop_url', $base_url);
+      mobile_tools_goto($destination);
     }
   }
 }
@@ -701,4 +703,4 @@
       ),
     ),
   );
-}
\ No newline at end of file
+}
