Logs showing WARNING when trying to credit bank accounts with Balanced Payments


Question: 

Been seeing this in my logs today.

  #############################################################
  #   WARNING! WARNING! WARNING! WARNING! WARNING! WARNING!   #
  #############################################################

  Using positional arguments is **DEPRECATED**. Please use the
  keyword options pattern instead. Version __0.7.0__ of the
  Ruby client will not support positional arguments.

The code that is responsible for that is:

bank_account.credit((amount*100).to_i)

What do I change? Couldn't find anything in the docs either. https://www.balancedpayments.com/docs/api?language=ruby#credit-an-existing-bank-account




2 Answers: 

bank_account.credit(:amount => (amount*100).to_i) should do the trick. The error you are getting is warning you from using positional arguments e.g.
def example(positional_arg1, positional_arg2);end

A good example of how to properly use the ruby client can be found here.

 

You should change this line to:

bank_account.credit(:amount => (amount*100).to_i)
 

More Articles


Azure DNS hostname or IP reference in web.config?

When connecting to Azure services in my applications, is it preferable to use the DNS hostname or the IP?For example, I have a SQL Server hosted in a virtual machine. Should I configure my web.config with 168.63.xxx.xxx or with mysqlserver001.cloudapp.net?Thanks

asp.net mvc - Payment Gateway returns Error HTTP Status - 400

I’m trying to redirect my MVC project to pay migs payment Gateway.Here’s the URL generated by my code. (For security reasons i have changed the value with the word “value” )https://migs.mastercard.com.au/vpcpay?vpc_AccessCode=value&vpc_Amount=100&vpc_Command=pay&vpc_Locale=en&vpc_Me

WebSocket closing immediately using Watson Speech-to-text JS SDK

Trying to use this code from a provided demo, using the latest watson-speech.js from https://github.com/watson-developer-cloud/speech-javascript-sdk:document.querySelector('#button').onclick = function () { fetch('myserverurl/api/token') .then(function(response) { return response.text(); }).


node.js - Microsoft Botframework Prompts.choice not getting validation response

I am using chatconnector to connect my Bot to an frontend chat app and writing the bot's response to my own database. The problem is when I am validating a prompt the bot responds but there's no API for me to grab the validation response. bot.dialog('/', [function (session) { builder.Prompts.cho

node.js - Firebase calling `child(all).equalTo(id)`

I like to check all children that contains a child with a value to the variable id.This is what I came up with:usersref.child(formData.openid + '/votes').child().equalTo(formData.appid).once('value', function(snapshot) {});This returned: Firebase.child failed: Was called with 0 arguments. Expects at

node.js - Correct way to send response when using Actions-on-google with koa.js

I'm trying to use actions-on-google with koa framework. I can't understand which request and response to use with AoG constructor in koa middleware. This is my code:const Koa = require( 'koa' )const koaBody = require('koa-body')const { DialogflowApp } = require('actions-on-google')const koaApp = new


actions on google - Implementing Conversation Webhook as Azure Function App

I have an azure function app that I am using as a webhook for my google assistant action. I've tried to follow the documentation for the proper response but I continually get the following error in the simulator when testing my webhook. Is there anything in my response message that looks wrong?Fai

java - Paypal expressCheckout integration (DoExpressCheckout) error

I have a ExpressCheckout integration setup in java google app engine and it working up to GetExpresschekout .but in finall call(DoExpressCheckout) I am unable to Authorize payment .it returnsan errorRESULT=1000&PNREF=E24P1FBB8FA4&RESPMSG=Generic processor error: 13116-The transaction is in p

c# - Set time limit for items in container in CosmosDB using Microsoft.Bot.Builder.Azure (bot framework v4)

I want to set the time to live for the items in a container in cosmosDB, but I am not sure how to do so using the config of cosmosdb storage in bot framework v4. I would appreciate some help on this matter.I have read about setting time to live using DocumentClient() as documented here. However I se

c# - How to connect with bot from another app?

I have created a core bot with basic workflow to collect information from end-users, which is hosted on http://localhost:3978, and exposes an endpoint to send message http://localhost:3978/api/messages (POST) I can start and chat with bot via Bot Framework Emulator, but I dont know how to interact w