class ResortPortalImageData < ActiveRecord::Migration[5.2]
  def change
    PortalImage.order(position: :asc).each_with_index do |image, index|
      image.update!(position: index + 1)
    end
  end
end
