The code powering m.abunchtell.com https://m.abunchtell.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

24 lines
374 B

  1. # frozen_string_literal: true
  2. class Api::SalmonController < ApiController
  3. before_action :set_account
  4. respond_to :txt
  5. def update
  6. body = request.body.read
  7. if body.nil?
  8. head 200
  9. else
  10. ProcessInteractionService.new.call(body, @account)
  11. head 201
  12. end
  13. end
  14. private
  15. def set_account
  16. @account = Account.find(params[:id])
  17. end
  18. end