mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-08-14 02:27:09 -07:00
Allow WebAPI to specify filename and mime type for result data
PR #20377.
This commit is contained in:
parent
8ef99b336c
commit
60bb819e2e
4 changed files with 43 additions and 19 deletions
|
@ -1442,5 +1442,5 @@ void TorrentsController::exportAction()
|
|||
if (!result)
|
||||
throw APIError(APIErrorType::Conflict, tr("Unable to export torrent file. Error: %1").arg(result.error()));
|
||||
|
||||
setResult(result.value());
|
||||
setResult(result.value(), u"application/x-bittorrent"_s, (id.toString() + u".torrent"));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue