Skip to content

Commit

Permalink
Fixed the handling of the "off" mode configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
lfhohmann committed Jun 23, 2021
1 parent 27a965e commit d92a634
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions custom_components/duckdns_ipv4_ipv6/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@

UPDATE_URL = "https://www.duckdns.org/update"
DEFAULT_HOSTNAME = "myip.opendns.com"
DEFAULT_IPV4_MODE = "off"
DEFAULT_IPV6_MODE = "off"
DEFAULT_IPV4_MODE = False
DEFAULT_IPV6_MODE = False
DEFAULT_IPV4_RESOLVER = "208.67.222.222"
DEFAULT_IPV6_RESOLVER = "2620:0:ccc::2"

Expand All @@ -46,10 +46,10 @@
vol.Required(CONF_ACCESS_TOKEN): cv.string,
vol.Optional(CONF_HOSTNAME, default=DEFAULT_HOSTNAME): cv.string,
vol.Optional(CONF_IPV4_MODE, default=DEFAULT_IPV4_MODE): vol.Any(
"off", "duckdns", "nameserver"
False, "duckdns", "nameserver"
),
vol.Optional(CONF_IPV6_MODE, default=DEFAULT_IPV6_MODE): vol.Any(
"off", "nameserver"
False, "nameserver"
),
vol.Optional(
CONF_IPV4_RESOLVER, default=DEFAULT_IPV4_RESOLVER
Expand Down

0 comments on commit d92a634

Please sign in to comment.