| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Got all the tests passing again.
Support for `encode_json` has been removed (and consequently the
ability to encode `BigDecimal`s as numbers, as mentioned in the
previous commit). Install the `activesupport-json_encoder` gem
to get it back.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
This is because the new encoder will no longer support encode_json.
Therefore our only choice is to return `to_i` or `to_s` in
`BigDecimal#as_json`. Since casting a BigDecimal to an integer is
most likely a lossy operation, we chose to encode it as a string.
Support for encoding BigDecimal as a string will return via the
`activesupport-json_encoder` gem.
|
| | | | |
|
| | | |
| | | |
| | | |
| | | | |
correctly
|
|/ / / |
|
| | | |
|
| | | |
|
|\ \ \
| | | |
| | | | |
changed update counter to act on unscoped model
|
|/ / / |
|
|\ \ \
| |/ /
|/| | |
remove leftover firebird adapter tests.
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
[ci skip]
This is a follow up to #12609 and integrates #12158.
Thanks @aspiers.
Closes #12158.
|
|/ / |
|
|/
|
|
|
|
|
|
|
|
|
| |
This prevents the following error when a MySQL index on a foreign key
column is renamed:
```
ActiveRecord::StatementInvalid: Mysql2::Error: Cannot drop index 'index_engines_on_car_id': needed in a foreign key constraint: DROP INDEX `index_engines_on_car_id` ON `engines`
```
refs: #13038.
|
|\
| |
| | |
Raise `RecordNotDestroyed` when children can't be replaced
|
| | |
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes #12812
Raise `ActiveRecord::RecordNotDestroyed` when a child marked with
`dependent: destroy` can't be destroyed.
The following code:
```ruby
class Post < ActiveRecord::Base
has_many :comments, dependent: :destroy
end
class Comment < ActiveRecord::Base
before_destroy do
return false
end
end
post = Post.create!(comments: [Comment.create!])
post.comments = [Comment.create!]
````
would result in a `post` with two `comments`.
With this commit, the same code would raise a `RecordNotDestroyed`
exception, keeping the `post` with the same `comment`.
|
| |
|
|\
| |
| | |
Fix some minor typos
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This reverts commit f4a5a9ea4d183f4102796215d4502c46dbe3e52b, reversing
changes made to 7ccb482181ee6c47c765406009018a15172812de.
Reason:
The logic is different, the first call to #option_value_selected? is for
the :selected option (the argument is the "selected" variable), the second
call is for the :disabled option (the argument is the "disabled" variable).
|
|\ \
| | |
| | | |
avoiding calling of #option_value_selected? two times
|
| | | |
|
|\ \ \
| |_|/
|/| | |
`delgated` => `delegated`
|
| | | |
|
|\ \ \
| | | |
| | | | |
Better error message for typos in assert_response argument.
|
|/ / /
| | |
| | |
| | |
| | | |
This commit makes it really easy to debug errors due to typos like
"assert_response :succezz".
|
|\ \ \
| | | |
| | | | |
Added `rewhere` usage to AR querying guides
|
|/ / / |
|
|\ \ \
| | | |
| | | | |
Raise RuntimeErrors with inspectable and MRI-independent messages.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Previous behaviour was MRI-dependent, now we're making sure the message
is correctly shown: something that can be relyied upon across every
Ruby implementation.
|
|\ \ \ \
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Conflicts:
activesupport/lib/active_support/core_ext/hash/deep_merge.rb
activesupport/lib/active_support/core_ext/hash/keys.rb
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
---
Revert "syntax error joining/including models"
This reverts commit ac35f72f30c47298a20a90c8c537db888b463bbb.
---
Revert "syntax error joining tables"
This reverts commit c365986b48c3e8bc8c7f3fa6a8521616ed5dc138.
---
Comments:
https://github.com/rails/docrails/commit/c365986b48c3e8bc8c7f3fa6a8521616ed5dc138#commitcomment-4630684
|
| | | | |
| | | | |
| | | | | |
syntax error joining/including models
|
| | | | |
| | | | |
| | | | | |
syntax error joining tables
|
| | | | | |
|
| | | | |
| | | | |
| | | | | |
Code style adherence
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | | |
[ci skip]
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
[ci skip] Enumerable.instance_methods &
Rails::Configuration::MiddlewareStackProxy.instance_methods # =>
[:as_json]
MiddlewareStackProxy does not share any notable methods with Enumerable.
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | | |
[ci skip]
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
According to our guideline, we leave 1 space between `#` and `=>`, so we
want `# =>` instead of `#=>`.
Thanks to @fxn for the suggestion.
[ci skip]
|
| | | | |
| | | | |
| | | | |
| | | | | |
[ci skip]
|
| | | | |
| | | | |
| | | | |
| | | | | |
[ci skip]
|
| | | | |
| | | | |
| | | | | |
Highlighted code
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Updated allow_failures for Rubinius 2.2.1.
|