Skip to content

Commit c48aab1

Browse files
committed
Remove deprecated ActiveSupport::Notifications::Event#children and ActiveSupport::Notifications::Event#parent_of?
1 parent fc2dc7c commit c48aab1

File tree

3 files changed

+6
-17
lines changed

3 files changed

+6
-17
lines changed

activesupport/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
* Remove deprecated `ActiveSupport::Notifications::Event#children` and `ActiveSupport::Notifications::Event#parent_of?`.
2+
3+
*Rafael Mendonça França*
4+
15
* Remove deprecated support to call the following methods without passing a deprecator:
26

37
- `deprecate`

activesupport/lib/active_support/notifications/instrumenter.rb

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -173,23 +173,6 @@ def allocations
173173
@allocation_count_finish - @allocation_count_start
174174
end
175175

176-
def children # :nodoc:
177-
ActiveSupport.deprecator.warn <<~EOM
178-
ActiveSupport::Notifications::Event#children is deprecated and will
179-
be removed in Rails 7.2.
180-
EOM
181-
[]
182-
end
183-
184-
def parent_of?(event) # :nodoc:
185-
ActiveSupport.deprecator.warn <<~EOM
186-
ActiveSupport::Notifications::Event#parent_of? is deprecated and will
187-
be removed in Rails 7.2.
188-
EOM
189-
start = (time - event.time) * 1000
190-
start <= 0 && (start + duration >= event.duration)
191-
end
192-
193176
# Returns the difference in milliseconds between when the execution of the
194177
# event started and when it ended.
195178
#

guides/source/7_2_release_notes.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -207,6 +207,8 @@ Please refer to the [Changelog][active-support] for detailed changes.
207207

208208
### Removals
209209

210+
* Remove deprecated `ActiveSupport::Notifications::Event#children` and `ActiveSupport::Notifications::Event#parent_of?`.
211+
210212
* Remove deprecated support to call the following methods without passing a deprecator:
211213

212214
- `deprecate`

0 commit comments

Comments
 (0)