added extra parameters to update function