_insert_callbacks

_insert_callbacks(callbacks, block = nil)
Instance Public methods

Take callback names and an optional callback proc, normalize them, then call the block with each callback. This allows us to abstract the normalization across several methods that use it.

Parameters

  • callbacks - An array of callbacks, with an optional options hash as the last parameter.

  • block - A proc that should be added to the callbacks.

Block Parameters

  • name - The callback to be added

  • options - A hash of options to be used when adding the callback

doc_ruby_on_rails
2015-06-20 00:00:00
Comments
Leave a Comment

Please login to continue.