Add an explanation on an obscure bit of the code.
This commit is contained in:
parent
0945d5ce7d
commit
7af50228b5
1 changed files with 3 additions and 0 deletions
|
|
@ -24,6 +24,9 @@ def _needs_env_data(method: Callable) -> Callable:
|
|||
"""
|
||||
|
||||
def wrapper(self, *args, **kwargs):
|
||||
# Many methods that use this decorator used to provide the option of passing in
|
||||
# an s3_reader different than the default one. Here, we check if the kwargs
|
||||
# contain one and, if so, use that instead of the default one.
|
||||
self.fetch_env_data(kwargs.get("s3_reader", None))
|
||||
return method(self, *args, **kwargs)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue