mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 12:11:33 -06:00
settings: add default=None to Group.get (#2178)
This is regular dict behavior/emulation.
This commit is contained in:
@@ -118,7 +118,7 @@ class Group:
|
||||
cls._type_cache = typing.get_type_hints(cls, globalns=mod_dict, localns=cls.__dict__)
|
||||
return cls._type_cache
|
||||
|
||||
def get(self, key: str, default: Any) -> Any:
|
||||
def get(self, key: str, default: Any = None) -> Any:
|
||||
if key in self:
|
||||
return self[key]
|
||||
return default
|
||||
|
Reference in New Issue
Block a user