file db unit tests and fixes
This commit is contained in:
parent
2df67abffb
commit
a0d653fff7
@ -92,9 +92,10 @@ auto rdb_file_db::add_directory(const std::string &api_path,
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
std::string existing_source_path;
|
||||
auto res = get_directory_source_path(api_path, existing_source_path);
|
||||
if (res != api_error::success && res != api_error::directory_not_found) {
|
||||
return res;
|
||||
auto result = get_directory_source_path(api_path, existing_source_path);
|
||||
if (result != api_error::success &&
|
||||
result != api_error::directory_not_found) {
|
||||
return result;
|
||||
}
|
||||
|
||||
return perform_action(
|
||||
@ -120,9 +121,9 @@ auto rdb_file_db::add_or_update_file(const i_file_db::file_data &data)
|
||||
REPERTORY_USES_FUNCTION_NAME();
|
||||
|
||||
std::string existing_source_path;
|
||||
auto res = get_file_source_path(data.api_path, existing_source_path);
|
||||
if (res != api_error::success && res != api_error::item_not_found) {
|
||||
return res;
|
||||
auto result = get_file_source_path(data.api_path, existing_source_path);
|
||||
if (result != api_error::success && result != api_error::item_not_found) {
|
||||
return result;
|
||||
}
|
||||
|
||||
return perform_action(
|
||||
|
Loading…
x
Reference in New Issue
Block a user