Sha256: bf283ac58f1d2ce5b6db4b595f94a1229f1b66d70f2e9813f08eb485fa9a6bc5

Contents?: true

Size: 289 Bytes

Versions: 66

Compression:

Stored size: 289 Bytes

Contents

class AddSuperuserToUsers < ActiveRecord::Migration
  def self.up
    add_column :users, :superuser, :boolean, :default => false
    unless (user = User.first).nil?
      user.update_attribute(:superuser, true)
    end
  end

  def self.down
    remove_column :users, :superuser
  end
end

Version data entries

66 entries across 66 versions & 2 rubygems

Version Path
refinerycms-0.9.5.27 db/migrate/20091207033335_add_superuser_to_users.rb
refinerycms-0.9.5.26 db/migrate/20091207033335_add_superuser_to_users.rb
refinerycms-0.9.5.25 db/migrate/20091207033335_add_superuser_to_users.rb
refinerycms-0.9.5.24 db/migrate/20091207033335_add_superuser_to_users.rb
refinerycms-0.9.5.23 db/migrate/20091207033335_add_superuser_to_users.rb
refinerycms-0.9.5.22 db/migrate/20091207033335_add_superuser_to_users.rb