diff options
Diffstat (limited to 'railties')
-rw-r--r-- | railties/lib/rails/generators/rails/app/app_generator.rb | 6 | ||||
-rw-r--r-- | railties/test/generators/api_app_generator_test.rb | 2 |
2 files changed, 6 insertions, 2 deletions
diff --git a/railties/lib/rails/generators/rails/app/app_generator.rb b/railties/lib/rails/generators/rails/app/app_generator.rb index 4ad78137f0..6d35fc61f0 100644 --- a/railties/lib/rails/generators/rails/app/app_generator.rb +++ b/railties/lib/rails/generators/rails/app/app_generator.rb @@ -252,17 +252,19 @@ module Rails end def create_tmp_files - build(:tmp) unless options[:api] + build(:tmp) end def create_vendor_files - build(:vendor) unless options[:api] + build(:vendor) end def delete_app_assets_if_api_option if options[:api] remove_dir 'app/assets' remove_dir 'lib/assets' + remove_dir 'tmp/cache/assets' + remove_dir 'vendor/assets' end end diff --git a/railties/test/generators/api_app_generator_test.rb b/railties/test/generators/api_app_generator_test.rb index fc4c101309..3d80af9323 100644 --- a/railties/test/generators/api_app_generator_test.rb +++ b/railties/test/generators/api_app_generator_test.rb @@ -72,6 +72,8 @@ class ApiAppGeneratorTest < Rails::Generators::TestCase test/controllers test/integration test/models + tmp + vendor ) files.concat %w(bin/bundle bin/rails bin/rake) files |