fix: typo in a func name in an error code path

Fixes #372
This commit is contained in:
Stéphane Lesimple 2023-03-14 09:55:57 +00:00 committed by Stéphane Lesimple
parent 9eac699954
commit a7c0b5ec23
2 changed files with 4 additions and 1 deletions

View file

@ -45,7 +45,7 @@ if (!$group || !$owner) {
HEXIT('ERR_MISSING_PARAMETER', msg => "Missing argument 'group' or 'owner'"); HEXIT('ERR_MISSING_PARAMETER', msg => "Missing argument 'group' or 'owner'");
} }
if ($no_key && ($algo || $size || $encrypted)) { if ($no_key && ($algo || $size || $encrypted)) {
EXIT('ERR_INVALID_PARAMETER', msg => "Can't specify 'no-key' along with 'algo', 'size' or 'encrypted'"); HEXIT('ERR_INVALID_PARAMETER', msg => "Can't specify 'no-key' along with 'algo', 'size' or 'encrypted'");
} }
if (!$no_key && (!$algo || !$size)) { if (!$no_key && (!$algo || !$size)) {
HEXIT('ERR_MISSING_PARAMETER', msg => "Missing argument 'algo' or 'size'"); HEXIT('ERR_MISSING_PARAMETER', msg => "Missing argument 'algo' or 'size'");

View file

@ -98,6 +98,9 @@ testsuite_groups()
plgfail a0_fail_create_group_reserved_2 $a0 --osh groupCreate --group keytothegate --no-key --owner $account1 plgfail a0_fail_create_group_reserved_2 $a0 --osh groupCreate --group keytothegate --no-key --owner $account1
json .command groupCreate .error_code ERR_INVALID_PARAMETER json .command groupCreate .error_code ERR_INVALID_PARAMETER
plgfail a0_fail_create_group_invalid_options $a0 --osh groupCreate --group invalid --no-key --algo ed25519 --owner $account1
json .command groupCreate .error_code ERR_INVALID_PARAMETER
success a0_create_g1_with_a1_as_owner $a0 --osh groupCreate --group $group1 --algo rsa --size 4096 --owner $account1 success a0_create_g1_with_a1_as_owner $a0 --osh groupCreate --group $group1 --algo rsa --size 4096 --owner $account1
contain "The public key of this group is" contain "The public key of this group is"
json $(cat <<EOS json $(cat <<EOS