Psalm 4 does not tell you to stop being angry. It assumes you are. What it asks is that you take the anger somewhere quiet and look at your own heart before you do anything with it.
Anger likes speed. Someone posts something about you online and your reply is half typed before you finish reading. Your teenager says something cutting at dinner and you match it. Your boss takes credit for your work and you spend the drive home writing the speech you will give tomorrow. Fast anger almost always ends in something you have to apologize for.
David wrote this psalm while people were damaging his reputation. He asks how long they will love worthless things and chase lies. He had real reasons to be angry. Yet in the middle of the psalm he turns and gives instructions. Be angry, but do not sin. On your bed, search your heart and be still.
The bed is a deliberate detail. It is the end of the day, when the noise has stopped and nobody is watching. David does not say to search the other person’s heart. He says to search your own. What exactly am I angry about? Is any of it mine? What do I want to happen, and is that justice or revenge?
Then he moves to trust. Offer right sacrifices and trust in the Lord. By the last verse he is lying down in peace and sleeping, because God makes him dwell in safety. The anger did not vanish because the problem was solved. It settled because he handed the outcome to God and examined himself instead of rehearsing his enemy’s faults.
None of this has to be answered tonight.
The next time anger hits you, especially late in the day, make a rule that you will not send, post, or say anything about it until morning. Before you sleep, lie still and ask God three plain questions: what am I really angry about, what part is mine, and what do I need to leave with You? Then decide in daylight what, if anything, to do.