If any person who shall be divorced on account of their being within the degrees prohibited by law, shall afterwards cohabit, they shall be liable to the pains and penalties provided by law against incest. If any persons who shall be divorced on account of a prior marriage, adultery, or other cause, shall afterwards cohabit, they shall be liable to all the pains provided by law against adultery.