Issue #2196807 by longwave, divesh.kumar: Convert all calls to check_plain() in core to Drupal\Component\Utility\String::checkPlain() in block module.

8.0.x
Nathaniel Catchpole 2014-02-20 12:05:15 +00:00
parent c26a7b0373
commit 0b929939a4
1 changed files with 2 additions and 1 deletions

View File

@ -7,6 +7,7 @@
namespace Drupal\block;
use Drupal\Component\Utility\String;
use Drupal\Core\Entity\EntityViewBuilder;
use Drupal\Core\Entity\EntityViewBuilderInterface;
use Drupal\Core\Entity\EntityInterface;
@ -61,7 +62,7 @@ class BlockViewBuilder extends EntityViewBuilder {
'#base_plugin_id' => $base_id,
'#derivative_plugin_id' => $derivative_id,
);
$build[$key]['#configuration']['label'] = check_plain($configuration['label']);
$build[$key]['#configuration']['label'] = String::checkPlain($configuration['label']);
// Place the $content returned by the block plugin into a 'content'
// child element, as a way to allow the plugin to have complete control