 If you make a sinful mistake, you should feel sorrow over it. That's an appropriate response for a believer. However, don't get stuck there. For, godly sorrow worketh repentance to salvation. God doesn't want you to forever live in the misery of that mistake. If we confess our sins, He is faithful and just to forgive us our sins and to cleanse us from all unrighteousness. It's healthy to feel a sense of brokenness over sin. No true believer feels comfortable in compromised living, but after you've acknowledged the sin and repented, it's time to move on. Oh, give me back my joy again. You have broken me. Now let me rejoice. Whether you made a mistake 10 years ago or 10 seconds ago, it's in the past. Repent, move on, and cooperate with the Holy Spirit as He helps you to do better.