instance method delete_multi

Ruby on Rails 8.1.2

Since v6.1.7.10

Available in: v6.1.7.10 v7.0.10 v7.1.6 v7.2.3 v8.0.4 v8.1.2

Signature

delete_multi(names, options = nil)

Deletes multiple entries in the cache. Returns the number of deleted entries.

Options are passed to the underlying cache implementation.

Parameters

names req
options opt = nil
Source
# File activesupport/lib/active_support/cache.rb, line 699
      def delete_multi(names, options = nil)
        return 0 if names.empty?

        options = merged_options(options)
        names.map! { |key| normalize_key(key, options) }

        instrument_multi(:delete_multi, names, options) do
          delete_multi_entries(names, **options)
        end
      end

Defined in activesupport/lib/active_support/cache.rb line 699 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActiveSupport::Cache::Store

Type at least 2 characters to search.

↑↓ navigate · open · esc close