Fix bug when delete a memo.