Changed the way I call the scheduler