feat(server): Handle creation of a webserver
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
@ -25,11 +25,11 @@ func GetListenAddressFromEnvOrFlags() (string, error) {
|
||||
pHost := flag.String("host", host, "Host address to listen to")
|
||||
pPort := flag.String("port", port, "Port to listen to")
|
||||
|
||||
if govalidator.IsHost(*pHost) {
|
||||
if !govalidator.IsHost(*pHost) {
|
||||
return "", fmt.Errorf("provided 'host' is invalid")
|
||||
}
|
||||
|
||||
if govalidator.IsPort(*pPort) {
|
||||
if !govalidator.IsPort(*pPort) {
|
||||
return "", fmt.Errorf("provided 'port' is invalid")
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user