Permalink
Browse files

Fix issue #569, prevent a little problem with DM and string length.

  • Loading branch information...
1 parent 00f828b commit 1b79dca7ca51221c79020eff0942dc2c5a3d2077 @DAddYE DAddYE committed Jun 30, 2011
Showing with 4 additions and 3 deletions.
  1. +3 −2 CHANGES.rdoc
  2. +1 −1 padrino-gen/lib/padrino-gen/generators/components/orms/datamapper.rb
View
@@ -25,8 +25,9 @@
* Controllers accept :conditions option [Thanks to Bernerdschaefer]
* Added Hungarian translation [Thanks to Kormány Zsolt]
* Added Riak support through Ripple
-* Updated couchrest_model dependency to ~>1.1.0.rc1
-* Fixed issue #571, don't handle Gemfile if we are outside a Padrino project
+* Updated couchrest_model dependency to ~>1.1.0
+* Fix issue #571, don't handle Gemfile if we are outside a Padrino project
+* Fix issue #569, prevent a little problem with DM and string length
== 0.9.29
@@ -93,7 +93,7 @@ def create_model_file(name, options={})
def create_model_migration(migration_name, name, columns)
output_model_migration(migration_name, name, columns,
- :column_format => Proc.new { |field, kind| "column :#{field}, #{kind.classify}" },
+ :column_format => Proc.new { |field, kind| "column :#{field}, #{kind.classify}#{', :length => 255' if kind =~ /string/i}" },
:base => DM_MIGRATION, :up => DM_MODEL_UP_MG, :down => DM_MODEL_DOWN_MG)
end

0 comments on commit 1b79dca

Please sign in to comment.