bug fix
code optimize