Quantcast
Channel: Question and Answer » views-contextual-filters
Viewing all articles
Browse latest Browse all 57

Views Log Error after upgrading to Drupal 7.43: “Undefined index: args in DatabaseLog…”

$
0
0

After upgrading from Drupal 7.41 to Drupal 7.43, I found that my Views are producing the following notice error when using PHP contextual filter code:

Notice: Undefined index: args in DatabaseLog->findCaller() (line 156 of .../includes/database/log.inc).

By debugging, I know that this is produced by PHP contextual filter in Views. Specifically by line 53 of views/plugins/views_plugin_argument_default_php.inc

Below is my PHP contextual filter code:

$filter = array();
if (module_exists('mymodule')) {
  $url = drupal_get_path_alias(current_path());
  $query = db_query(
  'SELECT cp.contact_person_id
   FROM {mymodule_table} cp
   WHERE cp.website_section_url LIKE :url_to_find', array(':url_to_find' => $url));
  foreach ($query as $row) {
    $filter[] = $row->contact_person_id;
  }
}
return implode('+',$filter);

The SQL query works correctly.
The view is a Block.
I am using the latest Views 7.x-3.13 version.

What could be happening?


Viewing all articles
Browse latest Browse all 57

Trending Articles