mirror of
https://github.com/kiwix/kiwix-desktop.git
synced 2025-09-23 03:58:56 -04:00
Use the encoded url when doing a request to the server.
This commit is contained in:
parent
f45ab71923
commit
639d16586f
@ -197,6 +197,7 @@ QStringList ContentManager::getDownloadIds()
|
||||
if (!mp_downloader)
|
||||
return list;
|
||||
for(auto& id: mp_downloader->getDownloadIds()) {
|
||||
qInfo() << QString::fromStdString(id);
|
||||
list.append(QString::fromStdString(id));
|
||||
}
|
||||
return list;
|
||||
@ -228,11 +229,11 @@ void ContentManager::updateRemoteLibrary() {
|
||||
url.setPort(CATALOG_PORT);
|
||||
url.setPath("/catalog/search");
|
||||
url.setQuery(query);
|
||||
qInfo() << "Downloading" << url;
|
||||
qInfo() << "Downloading" << url.toString(QUrl::FullyEncoded);
|
||||
m_remoteLibrary = kiwix::Library();
|
||||
kiwix::Manager manager(&m_remoteLibrary);
|
||||
try {
|
||||
auto allContent = kiwix::download(url.toString().toStdString());
|
||||
auto allContent = kiwix::download(url.toString(QUrl::FullyEncoded).toStdString());
|
||||
manager.readOpds(allContent, CATALOG_HOST);
|
||||
} catch (runtime_error&) {}
|
||||
emit(booksChanged());
|
||||
|
Loading…
x
Reference in New Issue
Block a user