-
Notifications
You must be signed in to change notification settings - Fork 194
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: NPE when adding a new service port #8803
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## release-0.8 #8803 +/- ##
===============================================
+ Coverage 65.14% 65.31% +0.17%
===============================================
Files 307 307
Lines 38516 38523 +7
===============================================
+ Hits 25090 25162 +72
+ Misses 11229 11164 -65
Partials 2197 2197
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
// TODO: how about the order changed? | ||
servicePorts := make(map[string]corev1.ServicePort) | ||
for i, port := range obj.Ports { | ||
servicePorts[port.Name] = obj.Ports[i] |
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.
port.Name is optional and omitempty?
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.
Change to use the port as the hash key.
@Y-Rookie PTAL |
8fdf0b8
to
b298eaf
Compare
close #8802