Adding the payment function which was missed while merging