correct scale error messages formatting

Co-authored-by: Milas Bowman <devnull@milas.dev>
Signed-off-by: Guillaume Lours <705411+glours@users.noreply.github.com>
This commit is contained in:
Guillaume Lours 2023-09-07 23:30:44 +02:00 committed by Nicolas De loof
parent 1a98a70b8a
commit 9d7e0ad6cb
1 changed files with 2 additions and 2 deletions

View File

@ -95,12 +95,12 @@ func parseServicesReplicasArgs(args []string) (map[string]int, error) {
for _, arg := range args {
key, val, ok := strings.Cut(arg, "=")
if !ok || key == "" || val == "" {
return nil, errors.Errorf("Invalide scale specifier %q.", arg)
return nil, errors.Errorf("invalid scale specifier: %s", arg)
}
intValue, err := strconv.Atoi(val)
if err != nil {
return nil, errors.Errorf("Invalide scale specifier, can't parse replicate value to int %q.", arg)
return nil, errors.Errorf("invalid scale specifier: can't parse replica value as int: %v", arg)
}
serviceReplicaTuples[key] = intValue
}