mirror of
https://github.com/Syping/dtranslatebot.git
synced 2026-04-21 14:40:41 +02:00
user_config: fix set_translator_settings() writing hostname in URL
This commit is contained in:
parent
4b1d0a6ff8
commit
5259e2777b
1 changed files with 1 additions and 1 deletions
|
|
@ -176,7 +176,7 @@ void user_config::set_translator_settings(const std::string &group, const dpp::j
|
||||||
m_key_file->set_integer(group, "Port", *json_port);
|
m_key_file->set_integer(group, "Port", *json_port);
|
||||||
auto json_url = json.find("url");
|
auto json_url = json.find("url");
|
||||||
if (json_url != json.end())
|
if (json_url != json.end())
|
||||||
m_key_file->set_string(group, "URL", static_cast<const std::string>(*json_hostname));
|
m_key_file->set_string(group, "URL", static_cast<const std::string>(*json_url));
|
||||||
auto json_apiKey = json.find("apiKey");
|
auto json_apiKey = json.find("apiKey");
|
||||||
if (json_url != json.end())
|
if (json_url != json.end())
|
||||||
m_key_file->set_string(group, "ApiKey", static_cast<const std::string>(*json_apiKey));
|
m_key_file->set_string(group, "ApiKey", static_cast<const std::string>(*json_apiKey));
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue