X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/cb87f02642d0097ebc067ca1f9371dde274a41e3..e1d681db3316673d8c3f26c2b0efc4a1382ddb73:/db/migrate/20121005195010_add_diary_entry_counter_caches.rb?ds=sidebyside diff --git a/db/migrate/20121005195010_add_diary_entry_counter_caches.rb b/db/migrate/20121005195010_add_diary_entry_counter_caches.rb index 1a61ddd41..ec05f3464 100644 --- a/db/migrate/20121005195010_add_diary_entry_counter_caches.rb +++ b/db/migrate/20121005195010_add_diary_entry_counter_caches.rb @@ -1,4 +1,10 @@ -class AddDiaryEntryCounterCaches < ActiveRecord::Migration[5.0] +class AddDiaryEntryCounterCaches < ActiveRecord::Migration[4.2] + class DiaryEntry < ApplicationRecord + end + + class User < ApplicationRecord + end + def self.up add_column :users, :diary_entries_count, :integer, :null => false, :default => 0