hanami / model

Ruby persistence framework with entities and repositories

Home Page:http://hanamirb.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Some alter-table methods are unavailable at migration

saiidalhalawi opened this issue · comments

Hi, I use following versions.

  • hanami (1.1.1)
  • sequel (4.49.0)

The document says set_column_allow_null is available at migration, but I've encountered undefined method error.

Hanami::Model.migration do
  change do
    set_column_allow_null :users, :address
  end
end
undefined method `set_column_allow_null' for #<Sequel::Mysql2::Database:0x00007f0b48099660>
Did you mean?  set_column_default

In addition, some other methods, like set_column_not_null or add_unique_constraint, are same.
It seems to be good the document is fixed, because I think these methods might be dispensable.

Do you think of it?
Thanks.

Thanks for opening this. I found this bug a year ago but forgot about it :(

See: #387 and #391

@cllns guide was fixed. Whoop