mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2024-11-25 02:36:10 +03:00
Merge pull request #13587 from Chocobo1/webapi
Avoid settings being reset via WebAPI
This commit is contained in:
commit
46ebf9b7e5
1 changed files with 4 additions and 2 deletions
|
@ -570,8 +570,10 @@ void AppController::setPreferencesAction()
|
|||
if (hasKey("max_ratio_act"))
|
||||
session->setMaxRatioAction(static_cast<MaxRatioAction>(it.value().toInt()));
|
||||
// Add trackers
|
||||
session->setAddTrackersEnabled(m["add_trackers_enabled"].toBool());
|
||||
session->setAdditionalTrackers(m["add_trackers"].toString());
|
||||
if (hasKey("add_trackers_enabled"))
|
||||
session->setAddTrackersEnabled(it.value().toBool());
|
||||
if (hasKey("add_trackers"))
|
||||
session->setAdditionalTrackers(it.value().toString());
|
||||
|
||||
// Web UI
|
||||
// Language
|
||||
|
|
Loading…
Reference in a new issue