-
Notifications
You must be signed in to change notification settings - Fork 40
Conversation
Thank you @piyush1594 for fixing issues in the Open Source spirit. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pkg/spec/resources.go
Outdated
@@ -669,9 +669,10 @@ func parsePortMapping(pm string) (*api_v1.ServicePort, error) { | |||
// Case 3 - port/protocol | |||
// Case 4 - port:targetPort/protocol | |||
case 2: | |||
switch api_v1.Protocol(protocolSplit[1]) { | |||
protocol_uppercase := strings.ToUpper(protocolSplit[1]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just one small nitpick 😇
protocolUpperCase
Go formatting style prefers camelCase names.
Yes, I know we have other variables with an underscore like api_v1
😄 , but that is a special case.
Normal variables should be camelCase
Code LGTM. Same as @kadel just change to camelCase and let's merge 👍 |
LGTM (after camelCase) |
This will accept if someone specifies protocol as tcp or Tcp or tCp. Likewise UDP also Always return the protocol as Uppercase Added test for two cases changed variable name to CamelCase
a954f7b
to
ced8e66
Compare
Changes requested by you are done. Please take a look. Thanks, @pradeepto @kadel @cdrage @surajnarwade |
LGTM! Thank you 👍 |
This will accept if someone specifies protocol as tcp or Tcp or tCp. Likewise UDP also Always return the protocol as Uppercase Added test for two cases changed variable name to CamelCase
This will accept if someone specifies protocol as tcp or Tcp or tCp. Likewise UDP also Always return the protocol as Uppercase Added test for two cases changed variable name to CamelCase
This will accept if someone specifies protocol as
tcp or Tcp or tCp. Likewise UDP also
Always return the protocol as Uppercase
Added test for two cases
#560