| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
Before:
>> ActiveRecord::Base.respond_to?(:find_by_something)
NoMethodError: undefined method `abstract_class?' for Object:Class
After:
>> ActiveRecord::Base.respond_to?(:find_by_something)
=> false
|
| |
|
|\
| |
| | |
Allow session serializer key in config.session_store
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
MessageEncryptor has :serializer option, where any serializer object can
be passed. This commit make it possible to set this serializer from configuration
level.
There are predefined serializers (:marshal_serializer, :json_serialzier)
and custom serializer can be passed as String, Symbol (camelized and
constantized in ActionDispatch::Session namepspace) or serializer object.
Default :json_serializer was also added to generators to provide secure
defalt.
|
|\ \
| |/
|/| |
Correctly send the string given to lock! and reload(:lock) to the lock scope - fixes #13788
|
|/
|
|
|
|
| |
- fixes #13788
As per the documentation at lock!, if the :lock option is a string it should use the given SQL to generate the lock statement.
|
|
|
|
| |
method signature
|
| |
|
|\
| |
| | |
Added documentation for css_compressor in asset_pipeline.md
|
| | |
|
|\ \
| | |
| | | |
Log for which keys values were set to nil in deep_munge
|
| |/
| |
| |
| |
| |
| |
| |
| | |
deep_munge solves CVE-2013-0155 security vulnerability, but its
behaviour is definately confuisng. This commit adds logging to deep_munge.
It logs keys for which values were set to nil.
Also mentions in guides were added.
|
|\ \
| |/
|/| |
Handle aliased attributes in AR::Relation#select, #order, etc.
|
|/
|
|
|
|
|
| |
With this we can write `Model#select(:aliased)`, `Model#order(:aliased)`,
`Model#reoder(aliased: :desc)`, etc.
Supplementary work to 54122067acaad39b277a5363c6d11d6804c7bf6b.
|
| |
|
|\
| |
| | |
Add docs about behaviour of replacing a has_one associate object.
|
| |
| |
| |
| |
| |
| |
| |
| | |
previous one is deleted even if the new one
doesn't get persisted to database.
Fixes #13197 . [ci skip]
|
|\ \
| | |
| | | |
Replace File.exists? with File.exist?
|
| | |
| | |
| | |
| | | |
To quell warnings on ruby 2.1
|
|\ \ \
| | | |
| | | | |
use the new clear_validators! api everywhere to reset validators in tests
|
|/ / / |
|
|\ \ \
| | | |
| | | | |
Rails config for raise on missing translations
|
| | | |
| | | |
| | | |
| | | |
| | | | |
Add a config to setup whether raise exception for missing translation or
not.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The request attributes filtered_parameters, filtered_env and filtered_path
are memoized for performance reasons. However this can cause unusual
behavior in tests where there are multiple calls to get, post, etc.
Fixes #13803.
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | | |
|
|\ \ \ \
| |/ / /
|/| | | |
Ability to specify multiple contexts when defining a validation.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Example:
validates_presence_of :name, on: [:update, :custom_validation_context]
|
|\ \ \ \
| |/ / /
|/| | | |
Display value when raising due to unscope() issues
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Hopefully make it easier to debug errors. e.g
Before:
RuntimeError:
unscope(where: "deleted_at") failed: unscoping String is unimplemented.
After:
RuntimeError:
unscope(where: "deleted_at") failed: unscoping String "'t'='t'" is unimplemented.
|
| | | |
| | | |
| | | |
| | | | |
#13820.
|
|\ \ \ \
| |/ / /
|/| | | |
Ruby on Rails 4.1 Release Notes: Fix spelling [ci skip]
|
|/ / / |
|
| | |
| | |
| | |
| | |
| | |
| | | |
Both Time#xmlschema and DateTime#xmlschema can accept nil values for the
fraction_digits parameter. This commit makes this so for TimeWithZone
values as well.
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The subsecond fraction digits had been hardcoded to 3. This forced all
timestamps to include the subsecond digits with no way to customize the
value. While the subsecond format is part of the ISO8601 spec, it is not
adhered to by all parsers (notably mobile clients). This adds the
ability to customize the number of digits used, optionally setting them
to 0 in order to eliminate the subsecond fraction entirely:
ActiveSupport::JSON::Encoding.subsecond_fraction_digits = 0
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | | |
Modern RDoc accepts a few more things in +...+. In particular symbols work now.
The current regexp in RDoc is https://github.com/rdoc/rdoc/blob/v4.1.1/lib/rdoc/markup/attribute_manager.rb#L133.
|
| | |
| | |
| | |
| | |
| | |
| | | |
& Xavier Noria]
Closes #11247.
|
|\ \ \
| |/ /
|/| | |
Fix order syntax in find_by_sql example [ci skip]
|
|/ / |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Currently if a time is changed during DST overlap in the autumn then the
method `period_for_local` will return the DST period. However if the
original time is not DST then this can be surprising and is not what is
generally wanted. This commit changes that behavior to maintain the current
period if it's in the list of periods returned by `periods_for_local`.
It is possible to alter the behavior of `period_for_local` by specifying a
second argument but since we may be change from another time that could be
either DST or not then this would give inconsistent results.
Fixes #12163.
|
| | |
|
| |
| |
| |
| |
| |
| | |
We allow the use of underscored symbols to represent classes throughout
other parts of Rails so it seems incongruous that it's not supported in
`register_interceptor` and `register_observer`.
|