Mat 1:19-20, 19 And her husband Joseph, being a just man and unwilling to put her to shame, resolved to divorce her quietly. 20 But as he considered these things, behold, an angel of the Lord appeared to him in a dream, saying, “Joseph, son of David, do not fear to take Mary as your wife, for that which is conceived in her is from the Holy Spirit”.
The marriage of Joseph and Mary was contracted but not complete. This new development would shake the core of the foundation of the upcoming marriage. God’s angel first appeared to Mary (Luke 1:26-38) and declared God’s plan. She received it without, if you will, checking with Joseph. The marriage plan was interrupted by pregnancy and not that of Joseph. Joseph being a just man pondered in his heart how to divorce her secretly without using the option of the law against Mary. This as we see spelled trouble, How will two walk unless they are agreed? But God.
In times of conflicts, misunderstandings, or seeking to be on the same page, we often need Divine intervention. Joseph was a just man and Mary was a virtuous woman, but their marriage would have been over without God. God had all the details covered. The angel in person and by name appeared to Mary, to Joseph an angel of the Lord, not in person or by name, appeared to him in a dream. In those different times and ways, God brought unity in diversity. Our marriages need the gospel. It reconciles us to God and to one another. Yield yourself to Him and His purposes and leave Him to deal with any contingent results.