Input (grade 7): In fact they had been doing some work for a local farmer and he had lent the boys the horse to ride home on.
Output (grade 6): They had been doing some work for a local farmer and he had lent the boys the horse to ride home on.