added a try to catch exceptions on scheduled