Skip to content

Commit

Permalink
Remove Rails-isms
Browse files Browse the repository at this point in the history
  • Loading branch information
johnnyshields committed Apr 26, 2023
1 parent e4eb445 commit 54b8a59
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion lib/paygate/profile.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ def purchase(currency, amount)
params = { profile_no: profile_no,
mid: member.mid,
goodcurrency: currency,
unitprice: amount }.delete_if { |_, v| v.blank? }
unitprice: amount }
params.compact!

# Make request
uri = URI(PURCHASE_URL)
Expand Down
2 changes: 1 addition & 1 deletion lib/paygate/transaction.rb
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def refund(options = {})
params.merge!(options.slice(:amount))
params[:amount] ||= FULL_AMOUNT_IDENTIFIER
params[:mb_serial_no] = options[:order_id]
params.delete_if { |_, v| v.blank? }
params.compact!

# Make request
uri = URI(self.class.refund_api_url)
Expand Down

0 comments on commit 54b8a59

Please sign in to comment.