1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-10 05:02:36 +01:00

Fixed issue when setting payment API key

This commit is contained in:
Hillel Coren 2014-08-04 06:34:53 -07:00
parent 0da7a1a6d1
commit 6662950e51

View File

@ -644,11 +644,14 @@ class AccountController extends \BaseController {
$config->$field = $value;
}
$cardCount = 0;
foreach($creditcards as $card => $value)
{
$cardCount += intval($value);
}
$cardCount = 0;
if ($creditcards)
{
foreach($creditcards as $card => $value)
{
$cardCount += intval($value);
}
}
$accountGateway->config = json_encode($config);
$accountGateway->accepted_credit_cards = $cardCount;