Changed function of scheduler across all code