diff --git a/modules/shortcut/shortcut.module b/modules/shortcut/shortcut.module index 2f6db0a..df423be 100644 --- a/modules/shortcut/shortcut.module +++ b/modules/shortcut/shortcut.module @@ -647,7 +647,7 @@ function shortcut_preprocess_page(&$variables) { // shortcuts and if the page's actual content is being shown (for example, // we do not want to display it on "access denied" or "page not found" // pages). - if (shortcut_set_edit_access() && ($item = menu_get_item()) && $item['access']) { + if (current_path() != 'system/404' && current_path() != 'system/403' && shortcut_set_edit_access() && ($item = menu_get_item()) && $item['access']) { $link = $_GET['q']; $query_parameters = drupal_get_query_parameters(); if (!empty($query_parameters)) { diff --git a/modules/statistics/statistics.test b/modules/statistics/statistics.test index 50accd7..d260607 100644 --- a/modules/statistics/statistics.test +++ b/modules/statistics/statistics.test @@ -157,8 +157,9 @@ class StatisticsLoggingTestCase extends DrupalWebTestCase { $this->drupalGet($long_path); $log = db_query('SELECT * FROM {accesslog}')->fetchAll(PDO::FETCH_ASSOC); $this->assertTrue(is_array($log) && count($log) == 8, 'Page request was logged for a path over 255 characters.'); - $this->assertEqual($log[7]['path'], truncate_utf8($long_path, 255)); + $this->assertEqual($log[7]['path'], 'system/404'); } + } /**