refactored code and workflow that updates max stops and assigns the stops to a max zone