aboutsummaryrefslogtreecommitdiff
path: root/src/zen/cmds/admin_cmd.cpp
diff options
context:
space:
mode:
authorzousar <[email protected]>2025-06-24 16:26:29 -0600
committerzousar <[email protected]>2025-06-24 16:26:29 -0600
commitbb298631ba35a323827dda0b8cd6158e276b5f61 (patch)
tree7ba8db91c44ce83f2c518f80f80ab14910eefa6f /src/zen/cmds/admin_cmd.cpp
parentChange to PutResult structure (diff)
parent5.6.14 (diff)
downloadarchived-zen-bb298631ba35a323827dda0b8cd6158e276b5f61.tar.xz
archived-zen-bb298631ba35a323827dda0b8cd6158e276b5f61.zip
Merge branch 'main' into zs/put-overwrite-policy
Diffstat (limited to 'src/zen/cmds/admin_cmd.cpp')
-rw-r--r--src/zen/cmds/admin_cmd.cpp14
1 files changed, 4 insertions, 10 deletions
diff --git a/src/zen/cmds/admin_cmd.cpp b/src/zen/cmds/admin_cmd.cpp
index 995ed4136..fe2bbbdc7 100644
--- a/src/zen/cmds/admin_cmd.cpp
+++ b/src/zen/cmds/admin_cmd.cpp
@@ -57,10 +57,7 @@ ScrubCommand::Run(const ZenCliOptions& GlobalOptions, int argc, char** argv)
}
else if (int StatusCode = (int)Response.StatusCode)
{
- ZEN_ERROR("scrub start failed: {}: {} ({})",
- (int)Response.StatusCode,
- ReasonStringForHttpResultCode((int)Response.StatusCode),
- Response.ToText());
+ ZEN_ERROR("scrub start failed: {}: {} ({})", StatusCode, ReasonStringForHttpResultCode(StatusCode), Response.ToText());
}
else
{
@@ -645,10 +642,7 @@ FlushCommand::Run(const ZenCliOptions& GlobalOptions, int argc, char** argv)
}
else if (int StatusCode = (int)Response.StatusCode)
{
- ZEN_ERROR("flush failed: {}: {} ({})",
- (int)Response.StatusCode,
- ReasonStringForHttpResultCode((int)Response.StatusCode),
- Response.ToText());
+ ZEN_ERROR("flush failed: {}: {} ({})", StatusCode, ReasonStringForHttpResultCode(StatusCode), Response.ToText());
}
else
{
@@ -688,7 +682,7 @@ Copy(const std::filesystem::path& Source, const std::filesystem::path& Target)
static bool
TryCopy(const std::filesystem::path& Source, const std::filesystem::path& Target)
{
- if (!std::filesystem::is_regular_file(Source))
+ if (!IsFile(Source))
{
return false;
}
@@ -714,7 +708,7 @@ CopyStateCommand::Run(const ZenCliOptions& GlobalOptions, int argc, char** argv)
throw OptionParseException("data path must be given");
}
- if (!std::filesystem::is_directory(m_DataPath))
+ if (!IsDir(m_DataPath))
{
throw OptionParseException("data path must exist");
}