Luke 6:45 “A good person produces good deeds from a good heart, and an evil person produces evil deeds from an evil heart. Whatever is in your heart determines what you say.”
Some people are very good at masquerading what is in their heart. Some show all the signs of having a godly heart, but sooner or later they do or say something that reveals what their heart is really like. If a person's heart is really right with God, then it will be evident in the consistent living of righteous. Godly people simply do not do what the world does. They separate themselves from what is obviously sin. The good deeds that they do flow from a genuine heart of love for both God and man.
When people do what they want, when they want to do it, and how they want to do it, it is a strong indicator that their heart is not right with God. Sinful deeds and words flow from a sinful heart. God's children do not say and do what evil people do. Period. Those who do evil either never knew Christ in the first place or they have wandered away from Christ and His grace into the cesspool of sin.
It is the heart's relationship with God that determines behavior and talk. No one right with God will act like they don't know God. What comes out of a man is determined by who is in the man. We must always carefully stand guard over our souls so that what comes out of us and what we do are right before God and pleasing to Him.