Issue #2904847 by mglaman, vaplas: Replace debug() statements in Views
parent
c7b8d93878
commit
566b7aa1bb
|
@ -185,7 +185,13 @@ abstract class FieldPluginBase extends HandlerBase implements FieldHandlerInterf
|
|||
}
|
||||
|
||||
if (empty($table_alias)) {
|
||||
debug(t('Handler @handler tried to add additional_field @identifier but @table could not be added!', ['@handler' => $this->definition['id'], '@identifier' => $identifier, '@table' => $info['table']]));
|
||||
trigger_error(sprintf(
|
||||
"Handler % tried to add additional_field %s but % could not be added!",
|
||||
$this->definition['id'],
|
||||
$identifier,
|
||||
$info['table']
|
||||
), E_USER_WARNING);
|
||||
|
||||
$this->aliases[$identifier] = 'broken';
|
||||
continue;
|
||||
}
|
||||
|
|
|
@ -56,8 +56,8 @@ class Opml extends StylePluginBase {
|
|||
*/
|
||||
public function render() {
|
||||
if (empty($this->view->rowPlugin)) {
|
||||
debug('Drupal\views\Plugin\views\style\Opml: Missing row plugin');
|
||||
return;
|
||||
trigger_error('Drupal\views\Plugin\views\style\Opml: Missing row plugin', E_WARNING);
|
||||
return [];
|
||||
}
|
||||
$rows = [];
|
||||
|
||||
|
|
|
@ -98,7 +98,7 @@ class Rss extends StylePluginBase {
|
|||
|
||||
public function render() {
|
||||
if (empty($this->view->rowPlugin)) {
|
||||
debug('Drupal\views\Plugin\views\style\Rss: Missing row plugin');
|
||||
trigger_error('Drupal\views\Plugin\views\style\Rss: Missing row plugin', E_WARNING);
|
||||
return [];
|
||||
}
|
||||
$rows = [];
|
||||
|
|
|
@ -457,8 +457,8 @@ abstract class StylePluginBase extends PluginBase {
|
|||
*/
|
||||
public function render() {
|
||||
if ($this->usesRowPlugin() && empty($this->view->rowPlugin)) {
|
||||
debug('Drupal\views\Plugin\views\style\StylePluginBase: Missing row plugin');
|
||||
return;
|
||||
trigger_error('Drupal\views\Plugin\views\style\StylePluginBase: Missing row plugin', E_WARNING);
|
||||
return [];
|
||||
}
|
||||
|
||||
// Group the rows according to the grouping instructions, if specified.
|
||||
|
|
|
@ -28,7 +28,7 @@ class ModuleTest extends ViewsKernelTestBase {
|
|||
public static $modules = ['field', 'user', 'block'];
|
||||
|
||||
/**
|
||||
* Stores the last triggered error, for example via debug().
|
||||
* Stores the last triggered error.
|
||||
*
|
||||
* @var string
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue