Fix typos: the indefinite articles(a -> an)

This commit is contained in:
SUGINO Yasuhiro 2013-09-13 17:44:35 +09:00
parent 489a0890b6
commit 4a36eb64a5
9 changed files with 11 additions and 11 deletions

@ -17,7 +17,7 @@ def initialize(status, block)
def call(env)
req = Request.new(env)
# If any of the path parameters has a invalid encoding then
# If any of the path parameters has an invalid encoding then
# raise since it's likely to trigger errors further on.
req.symbolized_path_parameters.each do |key, value|
unless value.valid_encoding?

@ -28,7 +28,7 @@ def initialize(options={})
def call(env)
params = env[PARAMETERS_KEY]
# If any of the path parameters has a invalid encoding then
# If any of the path parameters has an invalid encoding then
# raise since it's likely to trigger errors further on.
params.each do |key, value|
next unless value.respond_to?(:valid_encoding?)

@ -227,7 +227,7 @@ Action Pack
#### Deprecations
* Deprecated implied layout lookup in controllers whose parent had a explicit layout set:
* Deprecated implied layout lookup in controllers whose parent had an explicit layout set:
```ruby
class ApplicationController
@ -254,7 +254,7 @@ Action Pack
* Added `ActionDispatch::RequestId` middleware that'll make a unique X-Request-Id header available to the response and enables the `ActionDispatch::Request#uuid` method. This makes it easy to trace requests from end-to-end in the stack and to identify individual requests in mixed logs like Syslog.
* The `ShowExceptions` middleware now accepts a exceptions application that is responsible to render an exception when the application fails. The application is invoked with a copy of the exception in `env["action_dispatch.exception"]` and with the `PATH_INFO` rewritten to the status code.
* The `ShowExceptions` middleware now accepts an exceptions application that is responsible to render an exception when the application fails. The application is invoked with a copy of the exception in `env["action_dispatch.exception"]` and with the `PATH_INFO` rewritten to the status code.
* Allow rescue responses to be configured through a railtie as in `config.action_dispatch.rescue_responses`.

@ -327,7 +327,7 @@ class ProductsController < ApplicationController
end
```
Instead of a options hash, you can also simply pass in a model, Rails will use the `updated_at` and `cache_key` methods for setting `last_modified` and `etag`:
Instead of an options hash, you can also simply pass in a model, Rails will use the `updated_at` and `cache_key` methods for setting `last_modified` and `etag`:
```ruby
class ProductsController < ApplicationController

@ -103,7 +103,7 @@ numbers. New applications filter out passwords by adding the following `config.f
* `config.force_ssl` forces all requests to be under HTTPS protocol by using `ActionDispatch::SSL` middleware.
* `config.log_formatter` defines the formatter of the Rails logger. This option defaults to a instance of `ActiveSupport::Logger::SimpleFormatter` for all modes except production, where it defaults to `Logger::Formatter`.
* `config.log_formatter` defines the formatter of the Rails logger. This option defaults to an instance of `ActiveSupport::Logger::SimpleFormatter` for all modes except production, where it defaults to `Logger::Formatter`.
* `config.log_level` defines the verbosity of the Rails logger. This option defaults to `:debug` for all modes except production, where it defaults to `:info`.

@ -49,7 +49,7 @@ def self.exec_app_rails
# call to generate a new application, so restore the original cwd.
Dir.chdir(original_cwd) and return if Pathname.new(Dir.pwd).root?
# Otherwise keep moving upwards in search of a executable.
# Otherwise keep moving upwards in search of an executable.
Dir.chdir('..')
end
end

@ -293,7 +293,7 @@ class User < ActiveRecord::Base; raise 'should not be reached'; end
test "precompile should handle utf8 filenames" do
filename = "レイルズ.png"
app_file "app/assets/images/#{filename}", "not a image really"
app_file "app/assets/images/#{filename}", "not an image really"
add_to_config "config.assets.precompile = [ /\.png$/, /application.(css|js)$/ ]"
precompile!
@ -305,7 +305,7 @@ class User < ActiveRecord::Base; raise 'should not be reached'; end
require "#{app_path}/config/environment"
get "/assets/#{URI.parser.escape(asset_path)}"
assert_match "not a image really", last_response.body
assert_match "not an image really", last_response.body
assert_file_exists("#{app_path}/public/assets/#{asset_path}")
end

@ -110,7 +110,7 @@ def test_initializers_run_on_different_applications_go_to_the_same_class
assert_equal 0, $run_count, "Without loading the initializers, the count should be 0"
# Set config.eager_load to false so that a eager_load warning doesn't pop up
# Set config.eager_load to false so that an eager_load warning doesn't pop up
AppTemplate::Application.new { config.eager_load = false }.initialize!
assert_equal 3, $run_count, "There should have been three initializers that incremented the count"

@ -180,7 +180,7 @@ def setup
assert_equal 1, @root.eager_load.select {|p| p == @root["app"].expanded.first }.size
end
test "paths added to a eager_load path should be added to the eager_load collection" do
test "paths added to an eager_load path should be added to the eager_load collection" do
@root["app"] = "/app"
@root["app"].eager_load!
@root["app"] << "/app2"