fixed global object not reading