fix markdown saving