fixed bug in schedule system