Commit b9d71e79 authored by Volker Krause's avatar Volker Krause
Browse files

Handle quoted feed URLs in the NABSA systems.csv

parent d6cf4bf8
......@@ -69,11 +69,15 @@ void GBFSProbe::getFeedList()
while (!reply->atEnd()) {
auto line = reply->readLine();
line.replace("http:", "https:");
const auto idx = line.lastIndexOf(',');
const auto idx = line.lastIndexOf("https");
if (idx < 0) {
continue;
}
m_gbfsFeeds.push_back(QString::fromUtf8(line.mid(idx + 1).trimmed()));
line = line.mid(idx).trimmed();
if (line.endsWith('"')) {
line.chop(1);
}
m_gbfsFeeds.push_back(QString::fromUtf8(line));
}
std::sort(m_gbfsFeeds.begin(), m_gbfsFeeds.end());
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment