fix the unclosed callback