Fix RSS feed parsing

pull/81/head
Niels Andriesse 5 years ago
parent 2dc1a44087
commit efeefc4d0e

@ -19,7 +19,7 @@ public enum LokiRSSFeedProxy {
let url = URL(string: server + "/" + endpoint)!
let request = TSRequest(url: url)
return LokiFileServerProxy(for: server).perform(request).map { response -> String in
guard let data = response as? Data, let json = try? JSONSerialization.jsonObject(with: data, options: []) as? JSON, let xml = json["data"] as? String else { throw Error.proxyResponseParsingFailed }
guard let json = response as? JSON, let xml = json["data"] as? String else { throw Error.proxyResponseParsingFailed }
return xml
}
}

Loading…
Cancel
Save