adds digest to friends function