Fix to avoid pass by reference notice