Commit 4cbc2436fdd290ff5270156e287c98605a9625c8

Authored by Drew Blas
1 parent b365d9b4
Exists in master and in 1 other branch production

Fixed seed that tried to set protected attribute

Showing 1 changed file with 7 additions and 4 deletions   Show diff stats
@@ -10,10 +10,13 @@ puts "-- email: #{admin_email}" @@ -10,10 +10,13 @@ puts "-- email: #{admin_email}"
10 puts "-- password: #{admin_pass}" 10 puts "-- password: #{admin_pass}"
11 puts "" 11 puts ""
12 puts "Be sure to change these credentials ASAP!" 12 puts "Be sure to change these credentials ASAP!"
13 -User.create!({ 13 +u = User.create!({
14 :name => 'Errbit Admin', 14 :name => 'Errbit Admin',
15 :email => admin_email, 15 :email => admin_email,
16 :password => admin_pass, 16 :password => admin_pass,
17 - :password_confirmation => admin_pass,  
18 - :admin => true  
19 -})  
20 \ No newline at end of file 17 \ No newline at end of file
  18 + :password_confirmation => admin_pass
  19 +})
  20 +
  21 +#Admin is protected
  22 +u.admin=true
  23 +u.save
21 \ No newline at end of file 24 \ No newline at end of file