aboutsummaryrefslogtreecommitdiffstats
path: root/railties/lib/rails/generators/resource_helpers.rb
diff options
context:
space:
mode:
Diffstat (limited to 'railties/lib/rails/generators/resource_helpers.rb')
-rw-r--r--railties/lib/rails/generators/resource_helpers.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/railties/lib/rails/generators/resource_helpers.rb b/railties/lib/rails/generators/resource_helpers.rb
index 9c2037783e..0ea7418ba2 100644
--- a/railties/lib/rails/generators/resource_helpers.rb
+++ b/railties/lib/rails/generators/resource_helpers.rb
@@ -1,5 +1,5 @@
-require 'rails/generators/active_model'
-require 'rails/generators/model_helpers'
+require "rails/generators/active_model"
+require "rails/generators/model_helpers"
module Rails
module Generators
@@ -38,21 +38,21 @@ module Rails
def assign_controller_names!(name)
@controller_name = name
- @controller_class_path = name.include?('/') ? name.split('/') : name.split('::')
+ @controller_class_path = name.include?("/") ? name.split("/") : name.split("::")
@controller_class_path.map!(&:underscore)
@controller_file_name = @controller_class_path.pop
end
def controller_file_path
- @controller_file_path ||= (controller_class_path + [controller_file_name]).join('/')
+ @controller_file_path ||= (controller_class_path + [controller_file_name]).join("/")
end
def controller_class_name
- (controller_class_path + [controller_file_name]).map!(&:camelize).join('::')
+ (controller_class_path + [controller_file_name]).map!(&:camelize).join("::")
end
def controller_i18n_scope
- @controller_i18n_scope ||= controller_file_path.tr('/', '.')
+ @controller_i18n_scope ||= controller_file_path.tr("/", ".")
end
# Loads the ORM::Generators::ActiveModel class. This class is responsible