Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Fix description for AM::Callbacks | Vipul A M | 2015-01-31 | 1 | -1/+1 |
| | |||||
* | Deprecate `false` as the way to halt AM callbacks | claudiob | 2015-01-02 | 1 | -2/+1 |
| | | | | | | | | | | Before this commit, returning `false` in an ActiveModel `before_` callback such as `before_create` would halt the callback chain. After this commit, the behavior is deprecated: will still work until the next release of Rails but will also display a deprecation warning. The preferred way to halt a callback chain is to explicitly `throw(:abort)`. | ||||
* | Throw :abort halts default CallbackChains | claudiob | 2015-01-02 | 1 | -1/+1 |
| | | | | | | | | | | | | | | This commit changes arguments and default value of CallbackChain's :terminator option. After this commit, Chains of callbacks defined **without** an explicit `:terminator` option will be halted as soon as a `before_` callback throws `:abort`. Chains of callbacks defined **with** a `:terminator` option will maintain their existing behavior of halting as soon as a `before_` callback matches the terminator's expectation. For instance, ActiveModel's callbacks will still halt the chain when a `before_` callback returns `false`. | ||||
* | fix typo in in define_model_callbacks comment [ci skip] | Ryan Selk | 2014-10-03 | 1 | -1/+1 |
| | |||||
* | add notes for `define_model_callbacks` [ci skip] | Kuldeep Aggarwal | 2014-10-03 | 1 | -0/+3 |
| | |||||
* | Fix few typos in the documentation [ci skip] | Robin Dupret | 2013-12-21 | 1 | -1/+1 |
| | |||||
* | remove some evals from callback conditionals | Aaron Patterson | 2013-06-11 | 1 | -1/+4 |
| | |||||
* | deprecating string based terminators | Aaron Patterson | 2013-05-14 | 1 | -1/+1 |
| | |||||
* | Using define method instead of class eval when defining model callbacks. | wangjohn | 2013-05-08 | 1 | -18/+12 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Based on my benchmark results, this change improves performance substantially when defining callbacks. This benchmark (https://gist.github.com/wangjohn/5542610) was run using the current master and also using my experimental branch which replaced class_eval with define_single_method. Using class_eval (current master): user system total real 10 trials 0.000000 0.000000 0.000000 ( 0.001568) 50 trials 0.020000 0.000000 0.020000 ( 0.021715) 500 trials 0.110000 0.000000 0.110000 ( 0.115357) 1000 trials 0.250000 0.000000 0.250000 ( 0.260025) 10000 trials 2.560000 0.000000 2.560000 ( 2.568408) 50000 trials 12.800000 0.010000 12.810000 ( 12.886871) Using define_single_method (experimental branch): user system total real 10 trials 0.000000 0.000000 0.000000 ( 0.000790) 50 trials 0.000000 0.000000 0.000000 ( 0.002960) 500 trials 0.050000 0.010000 0.060000 ( 0.055690) 1000 trials 0.100000 0.000000 0.100000 ( 0.094073) 10000 trials 0.890000 0.000000 0.890000 ( 0.900364) 50000 trials 4.650000 0.000000 4.650000 ( 4.686127) | ||||
* | Convert ActiveModel to 1.9 hash syntax. | Patrick Robertson | 2013-05-01 | 1 | -4/+4 |
| | | | | | I also attempted to fix other styleguide violations such as { a: :b } over {a: :b} and foo(b: 'bar') over foo( b: 'bar' ). | ||||
* | Missing require extract_options | Akira Matsuda | 2013-01-31 | 1 | -0/+2 |
| | |||||
* | cleanup, removed dispensable `require` statements from `ActiveModel` | Yves Senn | 2012-11-25 | 1 | -2/+0 |
| | |||||
* | minor edits in AM documentation [ci skip] | Francesco Rodriguez | 2012-10-21 | 1 | -1/+1 |
| | |||||
* | add around_create callback documentation for ActiveModel::Callbacks | andrea longhi | 2012-08-08 | 1 | -0/+11 |
| | |||||
* | Make internal callback model definitions private in AMo | Carlos Antonio da Silva | 2012-06-25 | 1 | -5/+7 |
| | | | | | | | These _define class methods don't need to be exposed to objects that extend ActiveModel::Callbacks. Also use merge! options to avoid the creation of an extra hash. | ||||
* | add :nodoc: to internal implementations [ci skip] | Francesco Rodriguez | 2012-06-22 | 1 | -1/+1 |
| | |||||
* | update ActiveModel::Callbacks documentation [ci skip] | Francesco Rodriguez | 2012-06-22 | 1 | -24/+26 |
| | |||||
* | AS::Callbacks: :skip_after_callbacks_if_terminated option | Bogdan Gusiev | 2012-02-03 | 1 | -1/+2 |
| | |||||
* | Remove Array.wrap call in ActiveModel | Rafael Mendonça França | 2012-01-06 | 1 | -3/+2 |
| | |||||
* | Log 'Filter chain halted as CALLBACKNAME rendered or redirected' every time ↵ | José Valim | 2011-11-30 | 1 | -1/+1 |
| | | | | a before callback halts. | ||||
* | Small docs fix in Active Model callbacks module | Alexey Vakhov | 2011-11-19 | 1 | -1/+1 |
| | |||||
* | Remove extra white spaces on ActiveModel docs. | Sebastian Martinez | 2011-05-23 | 1 | -1/+1 |
| | |||||
* | Use run_callbacks; the generated _run_<name>_callbacks method is not a ↵ | John Firebaugh | 2011-01-31 | 1 | -4/+1 |
| | | | | | | public interface. Signed-off-by: Santiago Pastorino <santiago@wyeworks.com> | ||||
* | No need to symbolize these. | José Valim | 2010-12-27 | 1 | -1/+1 |
| | |||||
* | Deletes trailing whitespaces (over text files only find * -type f -exec sed ↵ | Santiago Pastorino | 2010-08-14 | 1 | -29/+29 |
| | | | | 's/[ \t]*$//' -i {} \;) | ||||
* | no callbacks should be created for empty array [#5289 state:resolved] | Subba Rao Pasupuleti | 2010-08-12 | 1 | -3/+6 |
| | | | | Signed-off-by: José Valim <jose.valim@gmail.com> | ||||
* | replacing around with for in the comments for callbacks | Neeraj Singh | 2010-07-22 | 1 | -1/+1 |
| | |||||
* | Changes call backs to callbacks. | Rizwan Reza | 2010-06-15 | 1 | -8/+8 |
| | |||||
* | Minor changes to active_model/callbacks.rb and dirty.rb | Rizwan Reza | 2010-06-14 | 1 | -1/+1 |
| | |||||
* | Minor changes to callbacks and conversion API docs. | Rizwan Reza | 2010-06-14 | 1 | -6/+6 |
| | |||||
* | fix stack trace lines on class_eval | Santiago Pastorino | 2010-04-09 | 1 | -3/+3 |
| | | | | Signed-off-by: José Valim <jose.valim@gmail.com> | ||||
* | Use Array.wrap uniformly | Jeremy Kemper | 2010-03-27 | 1 | -3/+4 |
| | |||||
* | ActiveModel::Callbacks documentation | Mikel Lindsaar | 2010-01-15 | 1 | -31/+73 |
| | |||||
* | Move ActiveRecord callbacks implementation to ActiveModel and make use of it. | José Valim | 2009-12-28 | 1 | -0/+91 |
| | | | | Signed-off-by: Yehuda Katz <wycats@Yehuda-Katz.local> | ||||
* | Get rid of active_model/core and active_model/callbacks | Pratik Naik | 2009-03-21 | 1 | -7/+0 |
| | |||||
* | initial statemachine machine and state classes | rick | 2008-06-28 | 1 | -1/+1 |
| | |||||
* | tweak activemodel load order a bit | rick | 2008-06-27 | 1 | -0/+2 |
| | |||||
* | initial experimental commit of active_model | Rick Olson | 2007-11-09 | 1 | -0/+5 |
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8118 5ecf4fe2-1ee6-0310-87b1-e25e094e27de |