I came to the Prophet ﷺ when I had long hair, and he said, "Unsightly." I thought he meant me, so I trimmed my hair and then came back to him. He said to me, "I did not mean you, but this is better."
أخبرنا محمود بن غيلان قال حدثنا سفيان أخو قبيصة ومعاوية بن هشام قالا حدثنا سفيان قال حدثنا عاصم بن كليب عن أبيه
أتيت النبي ﷺ ولي شعر فقال ذباب فظننت أنه يعنيني فأخذت من شعري ثم أتيته فقال لي لم أعنك وهذا أحسن
[Its chain is sahih] Abu Dawud narrated it in "Combing the Hair," the chapter on letting the hair grow long, hadith 4190, from the hadith of Sufyan bin Uqbah Sawai, transmitted this way. It also appears in Kubra, hadith 9307. The student of Asim bin Kulayb here is Thawri.