Allah's Messenger (ﷺ) used to give up a good deed, although he loved to do it, for fear that people might act
on it and it might be made compulsory for them. The Prophet (ﷺ) never prayed the Duha prayer, but I
offer it.
Sahih al-Bukhari Book 19, Hadith 8