mirror of
https://github.com/Mauler125/r5sdk.git
synced 2025-02-09 19:15:03 +01:00
Move banlist.config back to root dir due to its importance
This commit is contained in:
parent
d5b2e58dae
commit
2f30ce4a4c
@ -16,7 +16,7 @@ void CBanSystem::operator[](std::pair<std::string, std::int64_t> pair)
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBanSystem::Load()
|
||||
{
|
||||
std::filesystem::path path = std::filesystem::current_path() /= "platform\\cfg\\banlist.cfg"; // Get current path + banlist.config
|
||||
std::filesystem::path path = std::filesystem::current_path() /= "banlist.config"; // Get current path + banlist.config
|
||||
|
||||
nlohmann::json jsIn;
|
||||
std::ifstream banFile(path, std::ios::in); // Parse ban list.
|
||||
@ -67,7 +67,7 @@ void CBanSystem::Save()
|
||||
jsOut[std::to_string(i).c_str()]["originID"] = vsvBanList[i].second; // Populate originID field for this entry.
|
||||
}
|
||||
|
||||
std::filesystem::path path = std::filesystem::current_path() /= "platform\\cfg\\banlist.cfg"; // Get current path + banlist.config
|
||||
std::filesystem::path path = std::filesystem::current_path() /= "banlist.config"; // Get current path + banlist.config
|
||||
std::ofstream outFile(path, std::ios::out | std::ios::trunc); // Write config file..
|
||||
|
||||
outFile << jsOut.dump(4); // Dump it into config file..
|
||||
|
Loading…
x
Reference in New Issue
Block a user