refactor
This commit is contained in:
parent
cb93e34de0
commit
ff13633962
@ -238,13 +238,14 @@ auto encrypt_provider::get_directory_item_count(
|
||||
std::filesystem::directory_iterator(source_path)) {
|
||||
count++;
|
||||
}
|
||||
|
||||
return count;
|
||||
} catch (const std::exception &ex) {
|
||||
utils::error::raise_error(__FUNCTION__, ex, cfg.path,
|
||||
"failed to get directory item count");
|
||||
return 0U;
|
||||
}
|
||||
|
||||
return count;
|
||||
return 0U;
|
||||
}
|
||||
|
||||
auto encrypt_provider::get_directory_items(const std::string &api_path,
|
||||
@ -282,8 +283,8 @@ auto encrypt_provider::get_directory_items(const std::string &api_path,
|
||||
}
|
||||
|
||||
try {
|
||||
auto dir_iter = std::filesystem::directory_iterator(source_path);
|
||||
for (const auto &dir_entry : dir_iter) {
|
||||
for (const auto &dir_entry :
|
||||
std::filesystem::directory_iterator(source_path)) {
|
||||
try {
|
||||
std::string current_api_path{};
|
||||
if (dir_entry.is_directory()) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user