How do you solve a problem?

Separate the practical from the emotional.

Set aside the emotional.

Deal with the practical: assess the situation; identify the options; examine the pros and cons; pray, consult, etc.; make a plan; go with it.

Come back to the emotional, and sing this until you feel better.

Serenity Prayer in action.