He attacked the wraiths while it was daylight, instead of running away from the party the wraiths were after. He risked himself, even more than he knew at the time, angered very powerful wraiths - and undead have long memories and infinite grudges - and ultimately gained nothing. A very partial understanding of their daylight abilities and their use of horses wasn't worth a possibly-cursed wound that will probably require a full Restoration (and he can only afford so many of those). Even Merry's party didn't benefit; the remaining wraiths still had them at their mercy.
Recall: why did he do this? At the time, he thought that - wraiths are a menace to all living things, one must destroy them before they have a chance to breed more -
But the wraiths have been chasing the party for many days, at least. They could have turned them into wraiths already if they wanted to. He knew this when he ran off to fight them. He should have believed what Merry was implicitly telling him, that the wraiths didn't want to kill his party and very likely would keep on not killing it.
He let himself be rushed, and he made a wrong decision because of it. It hasn't cost him much (yet) but that was luck; the mistake is his to own.
...
If he had left and come back the next morning - assuming the party was still alive to continue their conversation - what would he do about the wraiths then? What can he do about the wraiths, with proper preparation?
He could kill all their horses, from a distance, if that's his goal. If he uses only summons, it might not even break Hide from Undead. If the wraiths can find him though, and if they attack, he would be in just as much danger. Ultimately, he still doesn't understand what they're using the horses for (or how they're using corporeal horses to begin with). It might be a worthwhile tactic, but only if he's already committed to attacking them, with all the risk that entails.
Anyway, letting the wraiths keep their horses makes them much more visible and findable, especially during the day; killing their horses might work out against him.
He doesn't know of any spell that would let him keep a wraith pinned down and unable to flee, even in daylight, for the rounds it would take him to destroy it. He never used his Searing Light, but two (three?) channels and a Cure Critical didn't take out a wraith, and a Searing Light is less powerful than all those together. Once the wraiths are sufficiently harmed, or once he destroys one, they will switch back to standard wraith tactics - hide during the day, attack invisibly in the night, float through the earth - and he can neither defend against it nor catch them again in the daylight if they abandon their horses.
...how does anyone destroy a bunch of wraiths that can just run away, including into the sky or underground? Stronger clerics have spells that'll do it in one round, but keeping them in place probably needs a wizard. His own blunt approach is clearly insufficient and he shouldn't try it again.
Next time, he will run away sooner.