mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 02:30:57 +08:00
71ea4ad7fc
Previous to this fix we were leaking methods on the internal action view template class per render. This caused email generation to be very low and a steady memory leak in the application in sidekiq when sending out emails The behavior change is new to Rails 6 so this fix does not need to be backported into stable.
14 lines
307 B
Ruby
14 lines
307 B
Ruby
# frozen_string_literal: true
|
|
|
|
class UserNotificationRenderer < ActionView::Base
|
|
include ApplicationHelper
|
|
include UserNotificationsHelper
|
|
include EmailHelper
|
|
|
|
def self.instance
|
|
@instance ||= UserNotificationRenderer.with_view_paths(
|
|
Rails.configuration.paths["app/views"]
|
|
)
|
|
end
|
|
end
|