I am modifying an existing .module file. I noticed I was getting an Undefined Variable notice for the $ context
variable that was occuring in the hook_render()
hook, eg:
function my_module_render($ conf) { $ block->content = [ '#theme' => 'my_module_panel', '#title' => $ conf['override_title'] ? ctools_context_keyword_substitute($ conf['override_title_text'], array(), $ context) : NULL, '#title_tag' => $ conf['override_title_heading'], ]; }
I tried removing it but this then Errored out the page (blank page, no noticed by error in the title).
I then tried adding the var to the function it’s self eg function my_module_render($ conf, $ context) {
but got the same error.
Would anyone know what I could do here?