Skip to content

Commit

Permalink
Added helper method for bucket logging.
Browse files Browse the repository at this point in the history
Signed-off-by: Stuart Paterson <[email protected]>
  • Loading branch information
Stuart Paterson committed Sep 6, 2018
1 parent d67cc8e commit fd3942b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions libraries/google_storage_bucket.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@ def has_versioning_enabled?
@bucket.versioning.enabled
end

def has_logging_enabled?
return false if !defined?(@bucket.logging)
return false if @bucket.logging.nil?
true
end

def to_s
"Bucket #{@display_name}"
end
Expand Down

0 comments on commit fd3942b

Please sign in to comment.