The Republicans invited him first, and his acceptance raised questions about whether Dolan, the head of the U.S. Conference of Catholic Bishops, was lending the authority of the Catholic hierarchy to the GOP. But then the Democrats shrewdly invited him to pray at their convention too. Dolan shrewdly accepted.
I don't get that excited about the perennial calls for civility in politics. Treating others with respect is important, and I certainly have no problem with political discourse that's even friendly and good-humored. But it's not clear that the latter serves any purpose beyond itself—that it builds understanding or encourages useful moderation or enables compromise. Chatting may be generally preferable to yelling, but it's not really a solution to division and gridlock.
I do, however, appreciate timely reminders that our neighbors include those we disagree with.