fizzy icon indicating copy to clipboard operation
fizzy copied to clipboard

Refactor: Use Rails range syntax in ActivitySpike query

Open italomatos opened this issue 2 weeks ago • 0 comments

Replace SQL string syntax with Rails range syntax for date filtering in the ActivitySpike::Detector. This improves code readability and follows Rails idioms.

Changed from:

 .where("created_at >= ?", recent_period.seconds.ago)

To:

  .where(created_at: recent_period.seconds.ago..)

This modernizes the codebase while maintaining the same functionality.

italomatos avatar Dec 11 '25 12:12 italomatos