You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: payments_controller.rb
    path of file: ./repos/wei/app/controllers
    
    the code of the file until where you have to start completion: class PaymentsController < ApplicationController
  def create
    order = Order.find(params[:order_id])
    payment = WxpubPaymentService.
    
  def params_transform
    raw_data = request.body.read
    notify_params = HashWithIndifferentAccess.new(Hash.from_xml(raw_data)['xml'])
    payment = Payment.find_by payment_no: notify_params[:out_trade_no]
    notify_params[:key] =  WxpubPayConfig.find(payment.pay_res_id).key
    notify_params
  end