private async Task RemoveAbsolutePath(HttpResponseMessage response) { var content = await response.Content.ReadAsStringAsync(); var replace = AnalyzerUtils.PatchToRelative(response.RequestMessage.RequestUri, content); if (replace != null) { _logger.LogInformation("[PATCH]"); response.Content = new StringContent(replace); } }
private RequestType GetRequestType(string url) { var type = AnalyzerUtils.GetRequestType(url); if (_request == RequestType.SEGMENT && type == RequestType.MANIFEST) { _logger.LogInformation("[TRACK SWITCH]"); } else if (type == RequestType.UNKNOWN) { _logger.LogWarning("Unknown Request type"); } return(type); }