Skip to content
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(binding-netconf): use optional chaining for non-null-assertion #1079

Merged
merged 1 commit into from
Sep 13, 2023

Conversation

JKRhb
Copy link
Member

@JKRhb JKRhb commented Sep 11, 2023

While working on #1078, I noticed that there is a warning emitted by eslint regarding the use of ! for non-null-assertions. This PR simply replaces the !s with ? (for optional chaining) which should avoid unwanted errors during runtime if one of the parameters should be undefined.

@codecov
Copy link

codecov bot commented Sep 11, 2023

Codecov Report

Patch coverage has no change and project coverage change: +0.01% 🎉

Comparison is base (c8177c2) 75.02% compared to head (7047b9b) 75.04%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1079      +/-   ##
==========================================
+ Coverage   75.02%   75.04%   +0.01%     
==========================================
  Files          80       80              
  Lines       15610    15607       -3     
  Branches     1499     1499              
==========================================
  Hits        11712    11712              
+ Misses       3862     3859       -3     
  Partials       36       36              
Files Changed Coverage Δ
packages/binding-netconf/src/async-node-netconf.ts 55.81% <0.00%> (+0.95%) ⬆️

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@JKRhb
Copy link
Member Author

JKRhb commented Sep 13, 2023

Given @danielpeintner's approval, I would merge this PR :)

@JKRhb JKRhb merged commit c10fba2 into eclipse-thingweb:master Sep 13, 2023
9 checks passed
@JKRhb JKRhb deleted the netconf-null-check branch September 13, 2023 13:34
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.

None yet

2 participants