I want to do a map on a rails collection but I need the result to be an active record collection instead of array. Currently I am doing the following but this returns an array.
MyModel.all.map do |model|
model.tap do |m|
response = fetcher.new.call(m.name)
m.rating = response[:rating]
end
end