Skip to content

Commit 4dde9cb

Browse files
committed
Make 'get_metadata' comments more developer-centric.
1 parent 294a428 commit 4dde9cb

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

gcloud/storage/bucket.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -349,8 +349,8 @@ def get_metadata(self, field=None, default=None):
349349
:rtype: dict or anything
350350
:returns: All metadata or the value of the specific field.
351351
"""
352-
# Use 'get_acl()' to retrieve the 'acl', and 'get_default_object_acl()'
353-
# to retrieve the 'defaultObjectAcl'.
352+
# We ignore 'acl' / 'defaultObjectAcl' because they should be
353+
# handled via 'get_acl()' / 'get_default_object_acl()'
354354
if field in ('acl', 'defaultObjectAcl'):
355355
return default
356356

gcloud/storage/key.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@ def get_metadata(self, field=None, default=None):
342342
:rtype: dict or anything
343343
:returns: All metadata or the value of the specific field.
344344
"""
345-
# Use 'get_acl()' to retrieve the 'acl'.
345+
# We ignore 'acl' because it is meant to be handled via 'get_acl()'.
346346
if field == 'acl':
347347
return default
348348

0 commit comments

Comments
 (0)