Reolink config flow fix custom port when USE_HTTPS not selected #91137
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Breaking change
Proposed change
When a user has configured a non-default port on the Reolink camera (besides port 80 and 443), the user needs to supply both the port and if HTTPS will be used. If only 1 of the two are given, they will be ignored and the default ports 80 and 443 will be used.
Currently the config flow form does not clearly show a "optional" boolean box, so it apears to be just off, however when the user does not press the USE_HTTPS box, the value will be None and even if they supplyed a port, it will not be used.
This PR makes sure USE_HTTPS box will always have a true/false value, so if a user puts in a port it will be used, if they leave the port empty, the default ports will be used.
Type of change
Additional information
Checklist
black --fast homeassistant tests
)If user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
Updated and included derived files by running:
python3 -m script.hassfest
.requirements_all.txt
.Updated by running
python3 -m script.gen_requirements_all
..coveragerc
.To help with the load of incoming pull requests: