mirror of
https://github.com/Freika/dawarich.git
synced 2026-01-10 01:01:39 -05:00
13 lines
320 B
Ruby
13 lines
320 B
Ruby
# frozen_string_literal: true
|
|
|
|
class PlaceVisitsCalculatingJob < ApplicationJob
|
|
queue_as :visit_suggesting
|
|
sidekiq_options retry: false
|
|
|
|
def perform(user_id)
|
|
user = User.find(user_id)
|
|
places = user.places # Only user-owned places (with user_id)
|
|
|
|
Places::Visits::Create.new(user, places).call
|
|
end
|
|
end
|