public function Broken::build in Drupal 10
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/Block/Plugin/Block/Broken.php \Drupal\Core\Block\Plugin\Block\Broken::build()
- 9 core/lib/Drupal/Core/Block/Plugin/Block/Broken.php \Drupal\Core\Block\Plugin\Block\Broken::build()
File
- core/
lib/ Drupal/ Core/ Block/ Plugin/ Block/ Broken.php, line 67
Class
- Broken
- Defines a fallback plugin for missing block plugins.
Namespace
Drupal\Core\Block\Plugin\BlockCode
public function build() {
$build = [];
if ($this->currentUser
->hasPermission('administer blocks')) {
$build += $this
->brokenMessage();
}
return $build;
}