Fix object reference bug.