Skip to content

Conversation

@csfmomo
Copy link
Contributor

@csfmomo csfmomo commented Jul 10, 2020

fix: add nil pointer checker when reading port value to avoid panic.

Reason for Change:
When generating network policy, customer could forget to fill in port value. No port value will result in panic due to nil pointer. Add check to avoid it.

fix: Bug Fixes 🐞

  • [X ] adds unit tests

@csfmomo csfmomo requested review from matmerr and neaggarwMS July 10, 2020 04:57
@codecov
Copy link

codecov bot commented Jul 10, 2020

Codecov Report

Merging #606 into master will decrease coverage by 0.46%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master     #606      +/-   ##
==========================================
- Coverage   39.88%   39.41%   -0.47%     
==========================================
  Files          42       47       +5     
  Lines        4586     5178     +592     
==========================================
+ Hits         1829     2041     +212     
- Misses       2502     2870     +368     
- Partials      255      267      +12     

Copy link
Member

@matmerr matmerr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for the test yaml, lgtm

@csfmomo csfmomo merged commit a537df1 into master Jul 10, 2020
@csfmomo csfmomo deleted the nilPointer branch July 10, 2020 21:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants