fix directory persistence