Fixing variable ref.