to-base supports parsing SRI hashes, so make type flag optional
This commit is contained in:
parent
d73dbc8e4c
commit
c502119fd3
1 changed files with 2 additions and 2 deletions
|
@ -79,12 +79,12 @@ static RegisterCommand r2("hash-path", [](){ return make_ref<CmdHash>(FileIngest
|
||||||
struct CmdToBase : Command
|
struct CmdToBase : Command
|
||||||
{
|
{
|
||||||
Base base;
|
Base base;
|
||||||
HashType ht;
|
std::optional<HashType> ht;
|
||||||
std::vector<std::string> args;
|
std::vector<std::string> args;
|
||||||
|
|
||||||
CmdToBase(Base base) : base(base)
|
CmdToBase(Base base) : base(base)
|
||||||
{
|
{
|
||||||
addFlag(Flag::mkHashTypeFlag("type", &ht));
|
addFlag(Flag::mkHashTypeFlag("type", &*ht));
|
||||||
expectArgs("strings", &args);
|
expectArgs("strings", &args);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue