Praying For A Troubled Marriage

Does praying for a troubled marriage work to bring back love, intimacy, and commitment with a straying spouse or simply a marriage that is hurting?