vendor/cache/ruby/2.3.0/gems/warden-github-1.3.2/lib/warden/github/membership_cache.rb
# Fetches a membership status by type and id (e.g. 'org', 'my_company')
# from cache. If no cached value is present or if the cached value
# expired, the block will be invoked and the return value, if true,
# cached for e certain time.
Fetches a membership status by type and id
from cache. If no cached value is present or if the cached value
expired, the block will be invoked and the return value, if true,
cached for e certain time.
Fetches a membership status by type and id from cache . If no cached value is present or if the cached value expired the block will be invoked and the return value if true cached for e certain time .
def fetch_membership(type, id)
        type = type.to_s
        id = id.to_s
        if cached_membership_valid?(type, id)
          true
        elsif block_given? && yield
          cache_membership(type, id)
          true
        else
          false
        end
      end
def fetch_membership ( type , id ) type = type . to_s id = id . to_s if cached_membership_valid? ( type , id ) true elsif block_given? && yield cache_membership ( type , id ) true else false end end
Fetches a membership status by type and id (e.g.
Fetches a membership status by type and id ( e . g .
type
<not_specific>
id
<not_specific>