| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| | |
Rails documentation use american english.[ci skip]
|
|/ |
|
|\
| |
| | |
Fix docs of AR::Timestamp to match #15726
|
|/
|
|
|
|
| |
[ci skip]
@sgrif can you review when you have time? Thanks!
|
| |
|
| |
|
|
|
|
|
| |
This method is specifically about the content type so lets remove the
parameter.
|
|
|
|
|
| |
create a singleton content type that just has nils, so that we don't
have to allocate a content type object all the time.
|
|
|
|
|
|
|
| |
If someone sets just a charset, but depends on the implicit type from
rendering, this will store a strange content type header that looks like
this: `; charset=blah`. This is so that when the content type header
is parsed again, it will return nil for the actual type.
|
|
|
|
|
| |
It turns out that the response object never really cares what the mime
type object is, so just use the string.
|
|
|
|
| |
pull content-type setting to a private method to dry it up.
|
|
|
|
|
| |
Instead of storing content type information in an ivar and a header,
lets move to just store the content type info in just the header.
|
|
|
|
| |
we'll use this method later to lazily parse content type headers.
|
| |
|
|
|
|
|
| |
everything above metal really doesn't care about setting the content
type, so lets rearrange these methods to be in metal.
|
|
|
|
|
|
|
| |
_set_content_type only does something when there is a request object,
otherwise the return value of _get_content_type is always ignored. This
commit moves everything to the module that has access to the request
object so we'll never to_s unless there is a reason
|
|
|
|
|
| |
in the future I would like to make the header hash read only (or at
least remove guarantees that mutations will do anything).
|
|\
| |
| | |
Properly log nested parameters to Active Job
|
|/
|
|
| |
Refactor arguments logging method for Active Job
|
|\
| |
| | |
Fix typo in activemodel changelog [ci skip]
|
| | |
|
| |
| |
| |
| | |
It's only used there.
|
| |
| |
| |
| |
| | |
`CookieJar` is only at the start of the chain and has its own
request method, so we don't need it in the module.
|
| |
| |
| |
| | |
It was the same in both legacy versions of the signed and encrypted cookie jars.
|
| |
| |
| |
| | |
The `EncryptedCookieJar` already calls it for us, so just delegate to its `parse` implementation.
|
| |
| |
| |
| |
| | |
`SignedCookieJar`'s parse method already attempts to verify the message,
so we can just call super and try the old verifier if it fails.
|
| |
| |
| |
| | |
Cuts down on the duplicated reading parts.
|
| |
| |
| |
| | |
Gets rid of the option parsing and makes what the encryptor does stand out.
|
| |
| |
| |
| | |
Lets us avoid worrying about parsing the options and doing just what we need.
|
| |
| |
| |
| | |
Remove the clutter to make PermanentCookieJar's one change stand out.
|
|/
|
|
| |
Eventually this will be the superclass of all the chained jars.
|
| |
|
|\
| |
| |
| |
| |
| | |
bernerdschaefer/bs-polymorphic-url_for-dups-arguments
`url_for` does not modify polymorphic options
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The `url_for` methods in `actionpack` and `actionview`
now make a copy of the provided options
before generating polymorphic paths or URLs.
The bug in the previous behavior
is most noticeable in a case like:
url_options = [:new, :post, param: 'value']
if current_page?(url_options)
css_class = "active"
end
link_to "New Post", url_options, class: css_class
|
|\ \
| | |
| | | |
Fixed Time conversion example for UTC time zone [ci skip]
|
| | | |
|
|\ \ \
| | | |
| | | | |
Validate multiple contexts on `valid?` and `invalid?` at once
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Example:
```ruby
class Person
include ActiveModel::Validations
attr_reader :name, :title
validates_presence_of :name, on: :create
validates_presence_of :title, on: :update
end
person = Person.new
person.valid?([:create, :update]) # => true
person.errors.messages # => {:name=>["can't be blank"], :title=>["can't be blank"]}
```
|
|\ \ \ \
| |_|/ /
|/| | | |
[Rails Guides] clarify `ActiveRecord::ConnectionTimeoutError`
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Original:
* ActiveRecord::ConnectionTimeoutError - could not obtain a database
connection within 5 seconds. The max pool size is currently 5;
consider increasing it:
Modified version:
* ActiveRecord::ConnectionTimeoutError - could not obtain a database
connection within 5.000 seconds (waited 5.000 seconds)
[ci skip]
|
|\ \ \ \
| | | | |
| | | | | |
Removes mandatory arguments from AR exceptions
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This change allows to instantiate all ActiveRecordError descendant
execption classes without arguments, which might be useful in testing
and is far less surprising than mandatory arguments.
|
|\ \ \ \ \
| | | | | |
| | | | | |
| | | | | | |
Define `SchemaStatements#tables` as interface
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
These 3 methods expect `ConnectionAdapters` to have `tables` method,
so make it clear that `tables` method is interface.
* `ConnectionAdapters::SchemaCache#prepare_tables`
* `db:schema:cache:dump` task
* `SchemaDumper#tables`
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
Replace AR with ActiveRecord to make it more readable [ci skip]
|
| |/ / / / / |
|
|\ \ \ \ \ \
| |/ / / / /
|/| | | | | |
Add tests for test/cases/adapters/mysql2/view_test.rb
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Basically view tests for MySQL are same with
`test/cases/adapters/postgresql/view_test.rb`.
So move `test/cases/adapters/postgresql/view_test.rb` to
`test/cases/view_test.rb` and make them only run if
`current_adapter` supports writable view.
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
raise LoadError when a non-existent file or directory is specified to the test runner
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
test runner sets file to be tested in plugin_rails_options,
but in plugin_rails_options, processing has been made to the argument of the
actual command rather than the argument of Minitest.run.
For example, if you run `./bin rake db:migrate test`, the options[:patterns], `db:migrate test` was incorrectly set.
|