lib/eco/api/session/batch/job.rb in eco-helpers-2.0.31 vs lib/eco/api/session/batch/job.rb in eco-helpers-2.0.32
- old
+ new
@@ -250,17 +250,17 @@
# if there is a config definition to exclude entries
# and the current batch is not a creation batch
# - filter out excluded entries from the api update
def api_included(full_queue)
return full_queue if type == :create
- return full_queue unless excluded = session.config.people.api_excluded
+ return full_queue unless excluded_callback = session.config.people.api_excluded
excluded = options.dig(:include, :excluded)
if excluded.is_a?(Hash) && excluded[:only]
- full_queue.select {|entry| excluded.call(entry, session, options, self)}
+ full_queue.select {|entry| excluded_callback.call(entry, session, options, self)}
elsif options.dig(:include, :excluded)
full_queue
else
- full_queue.select {|entry| !excluded.call(entry, session, options, self)}
+ full_queue.select {|entry| !excluded_callback.call(entry, session, options, self)}
end
end
# Applies the changes introduced by api policies
def apply_policies(pre_queue)