public static Dictionary FilterLogs()

in src/Middleware/Grpc/Server/CtxLogger.cs [61:71]


    public static Dictionary<string, object> FilterLogs(IMessage message)
    {
        var jsonFormatter = new JsonFormatter(new JsonFormatter.Settings(true));
        string jsonMessage = jsonFormatter.Format(message);

        JObject jObjectMessage = JObject.Parse(jsonMessage);
        Dictionary<string, object> fieldMap = JsonHelper.ConvertJObjectToDictionary(jObjectMessage);

        // Suppress the warning using the null-forgiving operator
        return FilterLoggableFields(fieldMap, message.Descriptor) ?? new Dictionary<string, object>();
    }