Phew, fixed functions and references