cache variables in resizePizzas funciton