Refactor: scheduler: best practices for pcmk__group_shutdown_lock()
Improve argument validation and variable names