Exit(1) when more than 1 jail matching provided name

This commit is contained in:
yo 2023-09-02 10:07:55 +02:00
parent 26ceb1630a
commit 7e1c213ff4

View File

@ -1,8 +1,9 @@
package cmd
import (
"errors"
"os"
"fmt"
"errors"
"reflect"
"strconv"
"strings"
@ -20,7 +21,7 @@ func GetJailProperties(args []string) {
jail, err = getJailFromArray(a, []string{""}, gJails)
if err != nil {
fmt.Printf("Error: %s\n", err.Error())
return
os.Exit(1)
}
} else {
props = append(props, a)