fix callback function empty bug