By podarok on
Change record status:
Published (View all published change records)
Project:
Introduced in branch:
main
Introduced in version:
main
Description:
no need to have a switch(){} for single case, use if, please
Before
switch ($block->getPluginId()) {
// Remove these blocks from Program page if Adv Profiles .
case 'save_programs_user_list':
if ($subtype == 0 || empty($user_data)) {
$event->stopPropagation();
}
break;
}
}
After
if ($block->getPluginId() == 'save_programs_user_list' && ($subtype == 0 || empty($user_data)) {
$event->stopPropagation();
}
Impacts:
Module developers
Comments
TODO
Fix it https://git.drupalcode.org/project/qs_profiles/-/merge_requests/1
---------------
Andrii Podanenko
CEO, ITCare