The warning comes after Wes Streeting published his WhatsApp exchanges with the former US ambassador.