Pārlūkot izejas kodu

convert protocol to string

abhishek9686 9 mēneši atpakaļ
vecāks
revīzija
2a106b4f5f
1 mainītis faili ar 5 papildinājumiem un 5 dzēšanām
  1. 5 5
      models/acl.go

+ 5 - 5
models/acl.go

@@ -16,13 +16,13 @@ const (
 )
 
 // Protocol - allowed protocol
-type Protocol int
+type Protocol string
 
 const (
-	ALL Protocol = iota
-	UDP
-	TCP
-	ICMP
+	ALL  Protocol = "all"
+	UDP  Protocol = "udp"
+	TCP  Protocol = "tcp"
+	ICMP Protocol = "icmp"
 )
 
 type AclPolicyType string