| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|\ \ \ \
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
dmitriy-kiriyenko/fix-double-callback-in-same-statement
Prevent callback from being set twice.
Conflicts:
activesupport/CHANGELOG.md
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
When you add one callack in two separate `set_callback` calls - it is
only called once.
When you do it in one `set_callback` call - it is called twice.
This violates the principle of least astonishment for me. Duplicating
callback is usually an error. There is a correct and obvious way to do
anything without this "feature".
If you want to do
before_save :clear_balance, :calculate_tax, :clear_balance
or whatever, you should better do
before_save :carefully_calculate_tax
def carefully_calculate_tax
clear_balance
calculate_tax
clear_balance
end
And this even opens gates for some advanced refactorings, unlike the
first approach.
My assumptions are:
- Principle of least astonishment is violated, when callbacks are either
prevented from duplication, or not.
- Duplicating callbacks is usually an error. When it is intentional -
it's a smell of a bad design and can be approached without abusing
this "feature".
My suggestion is: do not allow duplicating callbacks in one callback
call, like it is not allowed in separate callbacks call.
|
| | | | | |
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
We don't need to define a new method in ActiveMode::Errors for each
validatior.
See
https://github.com/rails/rails/commit/d72a07f1d1478db9daed847eadb35bfd840674f6#commitcomment-2325333
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Update security guide
|
| | |/ / /
| |/| | |
| | | | |
| | | | | |
securing sensitive files like database.yml and secret_token.rb
|
| | | | | |
|
|/ / / /
| | | |
| | | |
| | | |
| | | |
| | | | |
For some reason postgresql doesn't pass an integer value to load.
cc @tenderlove
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
from core_ext/logger" (some confusion over deprecation)
This reverts commit d00f568a83a5159ed93618b1081bd17858536d1c.
|
| | | |
| | | |
| | | |
| | | | |
core_ext/logger
|
| | | |
| | | |
| | | |
| | | | |
Logger#silence extension
|
|\ \ \ \ |
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This reverts commit e1f8ec59f2cc83f052b15233147aa2d6d8114a4d.
Reason: seems bad styling
[ci skip]
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The current section on controller specific assets does not really explain how the default application.css and application.js files
generated by rails will work with controller specific assets and is a bit ambiguous. We should remind users that they will be included
into their application by default but that they have the option to include them only where needed if they want and how this works with
precompiling assets.
[ci_skip]
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | | |
Fix #8575
|
| | | | |
| | | | |
| | | | |
| | | | | |
This will make the tests pass when the intrange datatype is not present
|
| | | | | |
|
| | | | | |
|
|\ \ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Fix document for String#humanize
Conflicts:
activesupport/lib/active_support/core_ext/string/inflections.rb
|
| | | | | | |
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
update AD::Journey to follow Rails coding conventions
|
| | | | | | | |
|
|/ / / / / /
| | | | | |
| | | | | | |
I missed attribution on this :flushed:
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Also some minor improvements to other changelogs. [ci skip]
|
| | | | | | |
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
nodoc Journey and remove unneeded Ruby <1.9 validation
|
| | | | | | | |
|
|/ / / / / / |
|
| | | | | | |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
[ci skip]
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Move the Journey code underneath the ActionDispatch namespace so
that we don't pollute the global namespace with names that may
be used for models.
Fixes rails/journey#49.
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
Attempt to fix slow runner name method
|
| | | | | | | |
|
|/ / / / / / |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
This reverts commit 29b1dc273e1ad6b9e13bf48fe3f12047850f9554.
Conflicts:
railties/test/application/paths_test.rb
Reason: since 7f96e4317e1354852e9600becb16662de3c17691 was reverted,
Path#children is no longer deprecated.
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
Leep index names when using `alter_table` with sqlite3. Closes #3489
|
| | | | | | | |
|
|\ \ \ \ \ \ \
| | | | | | | |
| | | | | | | | |
Address test_binary_data_is_not_logged with Oracle database
|
| |/ / / / / /
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
The number of sql statement logged depends on each database adapter
implementation.
Also, this test does not depends on how many sql statement executed.
|
|\ \ \ \ \ \ \
| | | | | | | |
| | | | | | | | |
Remove obfuscation support from mail_to helper
|
|/ / / / / / /
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Removes support for :encode, :replace_at, and :replace_dot
options from the mail_to helper. Support for these options
has been extracted to the 'actionview-encoded_mail_to' gem.
|
|\ \ \ \ \ \ \
| |/ / / / / /
|/| | | | | | |
Fix railties tests related to the addition of app/[models|controllers]/concerns, and improve changelog.
|
| | | | | | | |
|
|/ / / / / / |
|