diff --git a/lib/generators/acts_as_taggable_on/migration/templates/active_record/migration.rb b/lib/generators/acts_as_taggable_on/migration/templates/active_record/migration.rb index 16610615f..8add132ad 100644 --- a/lib/generators/acts_as_taggable_on/migration/templates/active_record/migration.rb +++ b/lib/generators/acts_as_taggable_on/migration/templates/active_record/migration.rb @@ -12,7 +12,9 @@ def self.up t.references :taggable, :polymorphic => true t.references :tagger, :polymorphic => true - t.string :context + # limit is created to prevent mysql error o index lenght for myisam table type. + # http://bit.ly/vgW2Ql + t.string :context, :limit => 128 t.datetime :created_at end