Skip to content

optimize: remove unnecessary null checks#7064

Merged
slievrly merged 5 commits intoapache:2.xfrom
MaoMaoandSnail:remove_net_exception_null_check
Feb 22, 2025
Merged

optimize: remove unnecessary null checks#7064
slievrly merged 5 commits intoapache:2.xfrom
MaoMaoandSnail:remove_net_exception_null_check

Conversation

@MaoMaoandSnail
Copy link
Contributor

  • I have registered the PR changes.

Ⅰ. Describe what this PR did

The return value of the ExceptionUtils.getNetExceptionType method will never be null. Remove the null check for the return value of this method.

Ⅱ. Does this pull request fix one issue?

Ⅲ. Why don't you add test cases (unit test/integration test)?

Ⅳ. Describe how to verify it

Ⅴ. Special notes for reviews

@codecov
Copy link

codecov bot commented Dec 19, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 52.65%. Comparing base (3b7e887) to head (7c5d041).
Report is 11 commits behind head on 2.x.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff              @@
##                2.x    #7064      +/-   ##
============================================
+ Coverage     52.59%   52.65%   +0.06%     
- Complexity     6613     6643      +30     
============================================
  Files          1128     1126       -2     
  Lines         40140    40142       +2     
  Branches       4704     4707       +3     
============================================
+ Hits          21111    21138      +27     
+ Misses        17016    16992      -24     
+ Partials       2013     2012       -1     

see 50 files with indirect coverage changes

Copy link
Member

@slievrly slievrly left a comment

Choose a reason for hiding this comment

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

LGTM

@slievrly slievrly merged commit c4b9b93 into apache:2.x Feb 22, 2025
5 of 6 checks passed
@slievrly slievrly added this to the 2.4.0 milestone Feb 22, 2025
slievrly pushed a commit to slievrly/fescar that referenced this pull request Oct 21, 2025
YvCeung pushed a commit to YvCeung/incubator-seata that referenced this pull request Dec 25, 2025
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