diff --git a/include/nil/blueprint/input_reader.hpp b/include/nil/blueprint/input_reader.hpp index b8410c00..40e6765d 100644 --- a/include/nil/blueprint/input_reader.hpp +++ b/include/nil/blueprint/input_reader.hpp @@ -429,21 +429,21 @@ namespace nil { bool is_private = current_arg->hasAttribute(llvm::Attribute::PrivateInput); if (is_private) { - if (private_input.size() == 0) { - error = "got argument with [[private_input]] attribute, but private input file was not provided or is empty (use -p flag to provide file name)."; - return false; - } if (private_input.size() <= priv_iter || !private_input[priv_iter].is_object()) { + if (private_input.size() == 0) { + error = "got argument with [[private_input]] attribute, but private input file was not provided or is empty (use -p flag to provide file name)."; + return false; + } error = "not enough values in the private input file."; return false; } } else { - if (public_input.size() == 0) { - error = "got argument without [[private_input]], but public input file was not provided or is empty (use -i flag to provide file name)."; - return false; - } if (public_input.size() <= pub_iter || !public_input[pub_iter].is_object()) { + if (public_input.size() == 0) { + error = "got argument without [[private_input]], but public input file was not provided or is empty (use -i flag to provide file name)."; + return false; + } error = "not enough values in the public input file."; return false; }