Kendrick battles out of a middle inning jam to get a win