[Web UI] Fix an error in Content tab when the torrent doesn't have metadata

Conflicts:
	src/webui/btjson.cpp
This commit is contained in:
ngosang 2015-07-09 18:11:04 +02:00 committed by sledgehammer999
commit 4c079ede83

View file

@ -502,7 +502,7 @@ QByteArray btjson::getFilesForTorrent(const QString& hash)
try { try {
QTorrentHandle h = QBtSession::instance()->getTorrentHandle(hash); QTorrentHandle h = QBtSession::instance()->getTorrentHandle(hash);
if (!h.has_metadata()) if (!h.has_metadata())
return QByteArray(); return json::toJson(file_list);
const std::vector<int> priorities = h.file_priorities(); const std::vector<int> priorities = h.file_priorities();
std::vector<size_type> fp; std::vector<size_type> fp;