Change my thoughts or my circomstances?

If I have a bad marriage and I tried everything and it’s not possible for relationship to improve, then what should I do? Should I change my thoughts to feel better or should I leave him? If I just want to leave him, then should I try to change my want? Because Brooke says that to want something is a thought and she also says that you can change how you feel right now without changing anything else but your thoughts.