mirror of
https://github.com/certbot/certbot.git
synced 2026-05-28 04:34:11 -04:00
Final typing fixes
This commit is contained in:
parent
8840618c2d
commit
f0f0b4db08
2 changed files with 4 additions and 2 deletions
|
|
@ -984,7 +984,9 @@ class ApacheConfigurator(common.Configurator):
|
|||
for arg in args:
|
||||
arg_value = self.parser.get_arg(arg)
|
||||
if arg_value is not None:
|
||||
addrs.add(obj.Addr.fromstring(arg_value))
|
||||
addr = obj.Addr.fromstring(arg_value)
|
||||
if addr is not None:
|
||||
addrs.add(addr)
|
||||
is_ssl = False
|
||||
|
||||
if self.parser.find_dir("SSLEngine", "on", start=path, exclude=False):
|
||||
|
|
|
|||
|
|
@ -261,7 +261,7 @@ class Addr:
|
|||
self.ipv6 = ipv6
|
||||
|
||||
@classmethod
|
||||
def fromstring(cls: Type[GenericAddr], str_addr: str) -> GenericAddr:
|
||||
def fromstring(cls: Type[GenericAddr], str_addr: str) -> Optional[GenericAddr]:
|
||||
"""Initialize Addr from string."""
|
||||
if str_addr.startswith('['):
|
||||
# ipv6 addresses starts with [
|
||||
|
|
|
|||
Loading…
Reference in a new issue