Update hook uses db_create_table($name, $table), but gives the function an extra empty array. This will lead to errors for users updating from old versions.

CommentFileSizeAuthor
#1 updatehook_fix-1884294.patch713 bytesstrykaizer

Comments

strykaizer’s picture

Assigned: Unassigned » strykaizer
Status: Active » Needs review
StatusFileSize
new713 bytes

fix in attachment

tanmayk’s picture

Assigned: strykaizer » Unassigned
Status: Needs review » Active

What about using drupal_install_schema() ?? Since it will create tables defined in hook_schema of module. First drop existing table and then just drupal_install_schema(). Any thoughts ??

arsirc’s picture

Assigned: Unassigned » arsirc
Status: Active » Fixed

new release with bugfix available ...

Thanks to StryKaizer you for the patch!!

tanmayk’s picture

Status: Fixed » Needs work

Is this really a good way to go? Since you are dropping the table and re-creating it, what about existing data ? I don't know, you might inserting it in module file somewhere, don't know about that. But still I am feeling that this is not complete solution. You should map existing data into new table, I think. :)

puravida’s picture

Issue summary: View changes
Status: Needs work » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.