fix bug about the duplicate save