update function newSharing of class sharing