diff options
Diffstat (limited to 'app/controllers/api/agents/files_controller.rb')
| -rw-r--r-- | app/controllers/api/agents/files_controller.rb | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/app/controllers/api/agents/files_controller.rb b/app/controllers/api/agents/files_controller.rb index 1329d04..b111048 100644 --- a/app/controllers/api/agents/files_controller.rb +++ b/app/controllers/api/agents/files_controller.rb @@ -9,12 +9,11 @@ module Api @agent = Agent.find(params[:agent_id]) @fingerprint = params[:id] @file = Disposition.find_by(fingerprint: params[:id]) - message = { + publish(EventMessage.new( agent_id: @agent.id, - type: :lookup, + event_type: :scanned, data: params[:data] - } - Publisher.publish("events.scanned.#{@agent.id}", message) + )) end end end |
