Debug the quantity update (again)