diff --git a/apdqc.module b/apdqc.module
index ec483b1..80f68b0 100644
--- a/apdqc.module
+++ b/apdqc.module
@@ -864,17 +864,24 @@ function apdqc_init() {
     }
   }
 
-  $router_item = menu_get_item();
-  // If this router item points to its parent, start from the parents to
-  // compute tabs and actions.
-  if ($router_item && ($router_item['type'] & MENU_LINKS_TO_PARENT)) {
-    $router_item = menu_get_item($router_item['tab_parent_href']);
-  }
-  // If we failed to fetch a router item or the current user doesn't have
-  // access to it, don't bother computing the tabs.
-  if ($router_item && $router_item['access']) {
-    // Get all tabs (also known as local tasks) and the root page.
-    $table_keys_cache_prefetch['cache_menu'][] = 'local_tasks:' . apdqc_escape_string($router_item['tab_root']);
+  if (function_exists('menu_get_item')) {
+    $router_item = menu_get_item();
+    // If this router item points to its parent, start from the parents to
+    // compute tabs and actions.
+    if ($router_item && ($router_item['type'] & MENU_LINKS_TO_PARENT)) {
+      $router_item = menu_get_item($router_item['tab_parent_href']);
+    }
+    // If we failed to fetch a router item or the current user doesn't have
+    // access to it, don't bother computing the tabs.
+    if ($router_item && $router_item['access']) {
+      // Get all tabs (also known as local tasks) and the root page.
+      $table_keys_cache_prefetch['cache_menu'][] = 'local_tasks:' . apdqc_escape_string($router_item['tab_root']);
+    }
+  }
+  else {
+    $backtrace = debug_backtrace(DEBUG_BACKTRACE_PROVIDE_OBJECT | DEBUG_BACKTRACE_IGNORE_ARGS);
+    $variables = array('@backtrace' => json_encode($backtrace, JSON_PRETTY_PRINT));
+    watchdog('apdqc', 'Missing menu_get_item(). Backtrace:<br><pre>@backtrace</pre>', $variables, WATCHDOG_ERROR);
   }
 
   if (module_exists('admin_menu')) {
