Skip to content

Commit

Permalink
Fix: Remove redundant error code argument from std::filesystem::exist…
Browse files Browse the repository at this point in the history
…s call

- Removed the second argument (error_code) from the std::filesystem::exists call in `parser.cpp`, as the function does not accept an error code parameter in C++17 and later.
- This resolves a compatibility issue with modern C++ standards.

Tested the change to ensure configuration files are correctly checked for existence without affecting error handling logic.
  • Loading branch information
gubatron committed Oct 22, 2024
1 parent 2e2929d commit cb99e60
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/config/parser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ bool parser::load_configuration_variables(variables_map& variables,

// If the existence test errors out we pretend there's no file :/.
error_code code;
if (!config_path.empty() && exists(config_path, code))
if (!config_path.empty() && exists(config_path))
{
const auto& path = config_path.string();
ifstream file(path);
Expand Down

0 comments on commit cb99e60

Please sign in to comment.