Disable broken activity tracking (#604)

This commit is contained in:
Max Wofford 2025-10-30 13:57:21 -04:00 committed by GitHub
parent bb48e11343
commit a7da824537
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -2,12 +2,11 @@ class PhysicalMail < ApplicationRecord
belongs_to :user
include PublicActivity::Model
tracked only: [ :create, :update ], owner: :user, params: proc { |controller, model|
{
mission_type: model.mission_type,
humanized_mission_type: model.humanized_mission_type
}
}
# tracked only: [ :update ], owner: :user, params: {
# mission_type: ->(controller, model) { model.mission_type },
# humanized_mission_type: ->(controller, model) { model.humanized_mission_type }
# }
after_create :create_streak_activity, if: :first_time_7_streak?
after_update :create_sent_activity, if: :became_sent?