Set closed data when saving issues (Fix #565)