mirror of https://github.com/rails/rails
Add `ActiveSupport` load hook for `ActionText::EncryptedRichText`
Both `ActionText::Record` and `ActionText::RichText` have dedicated `ActiveSupport` load hooks. This adds an additional hook for `ActionText::EncryptedRichText`, so that external libraries have a similarly simple way to run code after the subclass is loaded.
This commit is contained in:
parent
e55ccf0f10
commit
beb43e0182
|
@ -7,3 +7,5 @@ module ActionText
|
|||
encrypts :body
|
||||
end
|
||||
end
|
||||
|
||||
ActiveSupport.run_load_hooks :action_text_encrypted_rich_text, ActionText::EncryptedRichText
|
||||
|
|
|
@ -1488,6 +1488,7 @@ These are the load hooks you can use in your own code. To hook into the initiali
|
|||
| `ActionText::Content` | `action_text_content` |
|
||||
| `ActionText::Record` | `action_text_record` |
|
||||
| `ActionText::RichText` | `action_text_rich_text` |
|
||||
| `ActionText::EncryptedRichText` | `action_text_encrypted_rich_text` |
|
||||
| `ActionView::Base` | `action_view` |
|
||||
| `ActionView::TestCase` | `action_view_test_case` |
|
||||
| `ActiveJob::Base` | `active_job` |
|
||||
|
|
Loading…
Reference in New Issue