Refactor: scheduler: best practices for active_node()
Use true/false with bool, and improve variable names and formatting.