diff options
author | Evgeny Zinoviev <me@ch1p.io> | 2021-05-23 01:28:09 +0300 |
---|---|---|
committer | Evgeny Zinoviev <me@ch1p.io> | 2021-05-23 01:28:09 +0300 |
commit | 11e47bd708bde2c8e3ef3b6849b1dd7f8fbfe607 (patch) | |
tree | c427d2e90e6d36ddf5983a6abd38a46d8617db3b | |
parent | 867390d7f0779a507b91949c138861235a132b2b (diff) |
p18: fix set-charging-source-priority
-rw-r--r-- | src/p18/commands.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/p18/commands.cc b/src/p18/commands.cc index 1a8bc55..74a0571 100644 --- a/src/p18/commands.cc +++ b/src/p18/commands.cc @@ -328,7 +328,7 @@ p18::CommandType validate_input(std::string& command, throw std::invalid_argument("invalid id"); std::array<std::string, 3> priorities({"SF", "SU", "S"}); - long index = index_of(priorities, arguments[0]); + long index = index_of(priorities, arguments[1]); if (index == -1) throw std::invalid_argument("invalid argument"); |