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: crash on invalid zoomFactor #22673
Conversation
b5f7ae2
to
3f17fce
Compare
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.
😎
60114b4
to
c9e6d3d
Compare
Release Notes Persisted
|
I was unable to backport this PR to "7-1-x" cleanly; |
I was unable to backport this PR to "8-x-y" cleanly; |
I was unable to backport this PR to "9-x-y" cleanly; |
@codebytere has manually backported this PR to "9-x-y", please check out #22708 |
@codebytere has manually backported this PR to "8-x-y", please check out #22709 |
@codebytere has manually backported this PR to "7-1-x", please check out #22710 |
@codebytere has manually backported this PR to "7-2-x", please check out #22710 |
Description of Change
This PR fixes a crash caused by passing a value of
0.0
towebContents.setZoomFactor()
, seen below:It will now throw a descriptive error informing the user that values must be greater than 0.0. Also corrects docs which incorrectly stated that the zoomFactor was a Number and not a Double.
cc @MarshallOfSound @jkleinsc @zcbenz
Checklist
npm test
passesRelease Notes
Notes: Fixed a potential crash on invalid
zoomFactor
values when setting the zoom factor of a webpage.