fixed lost of reference