Sha256: 0cc1a8db352c69d4eccbe5f827ac3f769e5712cae4b87e0f954e944f3e17bfb6

Contents?: true

Size: 434 Bytes

Versions: 61

Compression:

Stored size: 434 Bytes

Contents

# frozen_string_literal: true

module SidekiqUniqueJobs
  # Normalizes hashes by dumping them to json and loading them from json
  #
  # @author Mikael Henriksson <mikael@mhenrixon.com>
  module Normalizer
    extend SidekiqUniqueJobs::JSON

    # Changes hash to a json compatible hash
    # @param [Hash] args
    # @return [Hash] a json compatible hash
    def self.jsonify(args)
      load_json(dump_json(args))
    end
  end
end

Version data entries

61 entries across 61 versions & 1 rubygems

Version Path
sidekiq-unique-jobs-8.0.10 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-7.1.33 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-7.1.32 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-8.0.9 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-8.0.8 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-8.0.7 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-8.0.6 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-7.1.31 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-8.0.5 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-8.0.4 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-7.1.30 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-8.0.3 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-8.0.2 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-8.0.1 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-8.0.0 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-7.1.29 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-7.1.28 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-7.1.27 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-7.1.26 lib/sidekiq_unique_jobs/normalizer.rb
sidekiq-unique-jobs-7.1.25 lib/sidekiq_unique_jobs/normalizer.rb