fix global var