The command to kill dogs, and its abrogation. The prohibition of keeping dogs, except for hunting, farming, (herding) livestock and the like Sahih Muslim 1570 a

Arabic hadith text
حَدَّثَنَا يَحْيَى بْنُ يَحْيَى، قَالَ قَرَأْتُ عَلَى مَالِكٍ عَنْ نَافِعٍ، عَنِ ابْنِ عُمَرَ، أَنَّ رَسُولَ اللَّهِ صلى الله عليه وسلمأَمَرَ بِقَتْلِ الْكِلاَبِ ‏.‏
Translation

Ibn 'Umar (Allah be pleased with them) reported Allah's Messenger (ﷺ) giving command for killing dogs.