Fix Subsonic API path

This commit is contained in:
Jonas Kvinge
2019-06-18 23:25:10 +02:00
parent beb3ab463f
commit dabd6f8284
3 changed files with 20 additions and 3 deletions

View File

@@ -73,7 +73,13 @@ QUrl SubsonicBaseRequest::CreateUrl(const QString &ressource_name, const QList<P
}
QUrl url(server_url());
url.setPath(QString("/rest/") + ressource_name);
if (url.path().right(1) == '/') {
url.setPath(url.path() + QString("rest/") + ressource_name);
}
else
url.setPath(url.path() + QString("/rest/") + ressource_name);
url.setQuery(url_query);
return url;