lib/zen/package/settings/migrations/1303196915_settings_plugin.rb in zen-0.2.5 vs lib/zen/package/settings/migrations/1303196915_settings_plugin.rb in zen-0.2.6

- old
+ new

@@ -5,18 +5,15 @@ rename_column(:settings, :group_key, :group) drop_column(:settings, :language_key) drop_column(:settings, :language_group_key) - # Ensure the identifiers are unique - #add_index(:settings, :key, :unique => true) - # Update the settings - Zen::Database.handle[:settings].all.each do |row| + Zen.database[:settings].all.each do |row| name = row[:name].split('.').last group = row[:group].split('.').last - Zen::Database.handle[:settings].filter(:id => row[:id]) + Zen.database[:settings].filter(:id => row[:id]) \ .update(:name => name, :group => group) end end down do