Finalize directory