function blocktheme_get in Block Theme 8
Same name and namespace in other branches
- 5 blocktheme.module \blocktheme_get()
- 6 blocktheme.module \blocktheme_get()
- 7 blocktheme.module \blocktheme_get()
Get Block Theme custom block settings.
4 calls to blocktheme_get()
- blocktheme_form_block_form_alter in ./
blocktheme.module - Form for updating a block.
- blocktheme_get_theme in ./
blocktheme.module - Get custom theme for a block.
- blocktheme_save in ./
blocktheme.module - Save a new block a after the block form has been submitted.
- blocktheme_update in ./
blocktheme.module - Update an existing block after the block form has been submitted.
File
- ./
blocktheme.module, line 180 - Provides a configuration option to select custom themes for blocks
Code
function blocktheme_get() {
static $blocktheme;
$config = Drupal::config('blocktheme.settings');
if (empty($blocktheme)) {
$blocktheme = $config
->get('blocktheme');
if (is_null($blocktheme)) {
$blocktheme = array();
}
}
return $blocktheme;
}