Method: Momento::CollectionTtl.refresh_ttl_if_provided
- Defined in:
- lib/momento/collection_ttl.rb
.refresh_ttl_if_provided(ttl_seconds = nil) ⇒ Momento::CollectionTtl
Creates a CollectionTtl that sets refresh to true if ttl_seconds is provided and false otherwise
46 47 48 |
# File 'lib/momento/collection_ttl.rb', line 46 def self.refresh_ttl_if_provided(ttl_seconds = nil) new(ttl_seconds, refresh_ttl: !ttl_seconds.nil?) end |