Sha256: 0a3c4687e59a17555d9331c12d5c4dd0be0180e329cf16306f96a411e536e575

Contents?: true

Size: 834 Bytes

Versions: 139

Compression:

Stored size: 834 Bytes

Contents

module Eco
  module API
    class MicroCases
      # When trying to find an `person` with given a source `entry`, it states if such a search should be `strict` or `soft`.
      # @note
      #   - `strict` searches ignore the email when the source `entry` has an `external_id` specified.
      #   - see related command line options `-search-strict` and `-search-soft`
      # @param options [Hash] the options.
      # @return [Boolean] `true` if the search should be `strict` only, and `false` otherwise.
      def strict_search?(options)
        strict_config  = session.config.people.strict_search?
        strict_option  = options.dig(:search, :strict)
        soft_option    = options.dig(:search, :soft) && !strict_option
        (strict_config || strict_option) && !soft_option
      end

    end
  end
end

Version data entries

139 entries across 139 versions & 1 rubygems

Version Path
eco-helpers-2.3.3 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.3.2 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.2.5 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.2.4 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.2.3 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.2.2 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.2.1 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.12 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.11 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.10 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.9 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.8 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.7 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.6 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.5 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.4 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.3 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.2 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.1.1 lib/eco/api/microcases/strict_search.rb
eco-helpers-2.0.68 lib/eco/api/microcases/strict_search.rb