1
0
mirror of https://github.com/fspc/BikeShed-1.git synced 2025-02-28 16:53:23 -05:00

fix if in seeds.rb

This commit is contained in:
Jason Denney 2012-12-08 16:34:39 -05:00
parent 3ce2cef2f6
commit 0d5b93b0b1

View File

@ -13,7 +13,7 @@ Dir.glob(File.join(Rails.root, 'db', 'seed', 'fixtures', '**', '*.{yml,csv}')).e
end
#Load bike brands and models from sql
if
if BikeBrand.all.empty? and BikeModel.all.empty?
sql_path = File.join(Rails.root, 'db', 'seed', 'sql', 'bike_brands_and_models.sql')
system "sqlite3 db/development.sqlite3 < #{sql_path}" if Rails.env.development?
end