Project

General

Profile

Defect #21993 ยป 0003-Raises-projects-description-limit-to-64KB.patch

okkez _, 2016-02-09 17:14

View differences:

db/migrate/20160209152147_change_projects_description_limit.rb
1
class ChangeProjectsDescriptionLimit < ActiveRecord::Migration
2
  def up
3
    if ActiveRecord::Base.connection.adapter_name =~ /mysql/i
4
      max_size = 64.kilobytes - 1
5
      change_column :projects, :description, :text, :limit => max_size
6
    end
7
  end
8

  
9
  def down
10
    # no-op
11
  end
12
end
    (1-1/1)