Skip to content

Commit

Permalink
#1690, fix logging remote IP for Cryptomus callbacks controller
Browse files Browse the repository at this point in the history
  • Loading branch information
Ivanov-Anton committed Feb 5, 2025
1 parent ef62686 commit 3cdb270
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/controllers/api/cryptomus_callbacks_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,13 @@

class Api::CryptomusCallbacksController < ActionController::API
include CaptureError::ControllerMethods
include WithPayloads
include Memoizable

rescue_from StandardError, with: :server_error

define_memoizable :debug_mode, apply: -> { System::ApiLogConfig.exists?(controller: self.class.name) }

# https://doc.cryptomus.com/payments/webhook
def create
payload = params.except(:controller, :action, :sign, :cryptomus_callback).to_unsafe_h.to_h
Expand Down

0 comments on commit 3cdb270

Please sign in to comment.