Check whether objects or prefixes exist in a bucket before attempting
operations that would fail on missing assets.
Usage
cdn_has_prefix(bucket, prefix)
cdn_has_object(bucket, key)
Arguments
- bucket
Character(1). A registered bucket name.
- prefix
Character(1). Path prefix to check (without trailing slash).
- key
Character(1). Full object key/path to check.
Value
TRUE if objects found, FALSE otherwise.
TRUE if object exists, FALSE otherwise.
Examples
if (FALSE) { # \dontrun{
cdn_has_prefix("art-data", "processed/artist-uuid/artwork-uuid")
} # }
if (FALSE) { # \dontrun{
cdn_has_object("art-public", "thumbnails/artist/artwork.jpeg")
} # }