When curses reside on your lips or in your heart it tells you that something is wrong. You are distressed. So, how do we handle distress? We pray through them!
In the opening of this verse we find David summarizing what the Psalm is about: God is my refuge. And it turns out to be a very good thing, as the psalm unfolds, because the situation David is in is pretty tough. But knowing this, as David does, is what enables him to stand up when all seems lost. In fact, say it to yourself again and again until it sticks in your brain. Because when you face distress, you need this truth ringing in your ears so that your distress brings you to the throne above. God is my refuge, thus I will pray through my distress.
To the choirmaster. Of David.
11:1 In the Lord I take refuge;
how can you say to my soul,
“Flee like a bird to your mountain,
2 for behold, the wicked bend the bow;
they have fitted their arrow to the string
to shoot in the dark at the upright in heart;
3 if the foundations are destroyed,
what can the righteous do?”
4 The Lord is in his holy temple;
the Lord's throne is in heaven;
his eyes see, his eyelids test the children of man.
5 The Lord tests the righteous,
but his soul hates the wicked and the one who loves violence.
6 Let him rain coals on the wicked;
fire and sulfur and a scorching wind shall be the portion of their cup.
7 For the Lord is righteous;
he loves righteous deeds;
the upright shall behold his face. (ESV)