class AssignDefaultValueToPlaylistTags < ActiveRecord::Migration
  def change
    # Default value of [] for tags is being set by an after_initialize callback
    Playlist.where(tags: nil).each {|p| p.save!(validate: false) }
  end
end

Migrate old playlists so they sort properly on the tags field
Migrate old playlists so they sort properly on the tags field
