Skip to content

Instantly share code, notes, and snippets.

@bcmiller
Created June 17, 2010 18:26
Show Gist options
  • Save bcmiller/442516 to your computer and use it in GitHub Desktop.
Save bcmiller/442516 to your computer and use it in GitHub Desktop.
> +++ includes/views/handlers/content_plugin_style_php_array_ac.inc 4 May 2010 23:22:02 -0000
23,60d21
< @@ -21,14 +26,16 @@ class content_plugin_style_php_array_ac
< $this->view->row_index = 0;
< foreach ($sets as $title => $records) {
< foreach ($records as $label => $row) {
< - $results[$row->{$base_field}] = array(
< - 'title' => $row->{$title_field_alias},
< - 'rendered' => $this->row_plugin->render($row),
< - );
< - $this->view->row_index++;
< + if( !is_null($row->{$base_field}) ) {
< + $results[$row->{$base_field}] = array(
< + 'title' => $row->{$title_field_alias},
< + 'rendered' => $this->row_plugin->render($row),
< + );
< + $this->view->row_index++;
< + }
< }
< - }
< - unset($this->view->row_index);
< - return $results;
< }
< + unset($this->view->row_index);
< + return $results;
< +}
< }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment