This commit is contained in:
2020-07-01 12:50:46 +02:00
parent e571f7bb3e
commit ef564e382c
3 changed files with 29 additions and 23 deletions

View File

@ -1011,6 +1011,9 @@ std::string CmdProxy::Scan(int action) {
os << OutString(t) << '\n';
} else if (action == defs::PUT_ACTION) {
if (args.size() == 1) {
if (StringTo<int>(args[0]) != 0) {
throw sls::RuntimeError("Did you mean '0' to disable?");
}
det->disableScan();
os << "scan disabled" << '\n';
} else if (args.size() != 4) {