Change the function to have the json with common friend

Signed-off-by: Sp1p3 <aldorane22@hotmail.fr>