Fix: storing references is not working