Fixed scheduler script