made minior changes to scheduler