/// <summary> /// Assigns the request body. /// </summary> /// <param name="rollbarData">The rollbar data.</param> private void AssignRequestBody(Data rollbarData) { if (this._httpRequest == null || this._httpRequest.Body == null) { return; // nothing to do... } string jsonString = StreamUtil.ConvertToString(this._httpRequest.Body); if (string.IsNullOrWhiteSpace(jsonString)) { return; } rollbarData.Request.PostBody = jsonString; object requesBodyObject = JsonUtil.InterpretAsJsonObject(jsonString); if (requesBodyObject != null) { rollbarData.Request.PostBody = requesBodyObject; } }