Narrated Abu Hurairah: Allah’s Messenger, peace be upon him, sent us on a military expedition telling us, “If you find such and such persons, burn them with fire.” Then we came to bid him farewell, when we wanted to set out, he said, “Previously I ordered you to burn so-and-so and so-and-so with fire, but as punishment with fire is done by none except Allah, if you capture them, kill them (instead).”
[4: 202(B) — O.B. Sahih Al-Bukhari)

Narrated Abu Hurairah: I heard Allah’s Messenger, peace be upon him, as saying, “An ant bit a Prophet amongst the Prophets, and he ordered that the place of the ants be burnt. So, Allah inspired to him, ‘It is because one ant bit you that you burnt a nation amongst the nations that glorify Allah?”
[4: 261(B) — O.B. Sahih Al-Bukhari)