function blocktheme_get_vars in Block Theme 8
Same name and namespace in other branches
- 6 blocktheme.module \blocktheme_get_vars()
- 7 blocktheme.module \blocktheme_get_vars()
Get Block Theme custom block variables settings.
4 calls to blocktheme_get_vars()
- blocktheme_form_block_form_alter in ./
blocktheme.module - Form for updating a block.
- blocktheme_get_theme_vars in ./
blocktheme.module - Get custom variables 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 196 - Provides a configuration option to select custom themes for blocks
Code
function blocktheme_get_vars() {
static $blocktheme_vars;
$config = Drupal::config('blocktheme.settings');
if (empty($blocktheme_vars)) {
$blocktheme_vars = $config
->get('blocktheme_vars');
if (is_null($blocktheme_vars)) {
$blocktheme_vars = array();
}
}
return $blocktheme_vars;
}