mirror of
https://github.com/Freika/dawarich.git
synced 2026-01-12 18:21:38 -05:00
17 lines
299 B
Ruby
17 lines
299 B
Ruby
|
|
# frozen_string_literal: true
|
||
|
|
|
||
|
|
module Imports::Broadcaster
|
||
|
|
def broadcast_import_progress(import, index)
|
||
|
|
ImportsChannel.broadcast_to(
|
||
|
|
import.user,
|
||
|
|
{
|
||
|
|
action: 'update',
|
||
|
|
import: {
|
||
|
|
id: import.id,
|
||
|
|
points_count: index
|
||
|
|
}
|
||
|
|
}
|
||
|
|
)
|
||
|
|
end
|
||
|
|
end
|