Optimize retrieval of commits on pull req comment processing