One of parameters (value: ) is not of the type Boolean
Hi all,
Attempting to set up Stripe for a client, but having a few issues... I've set up the test and live publishable and secret keys, along with the webhooks supplied.
When going through a Contribution Form, filling out the fields and then clicking "Make Contribution", I am presented with a CiviCCRM Error. I've included the backtrace here:
#0 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Core/Error.php(377): CRM_Core_Error::backtrace()
#1 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Utils/Type.php(554): CRM_Core_Error::fatal("One of parameters (value: ) is not of the type Boolean")
#2 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Core/DAO.php(1518): CRM_Utils_Type::validate("", "Boolean")
#3 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Core/DAO.php(1482): CRM_Core_DAO::composeQuery("SELECT id\n FROM civicrm_stripe_customers\n WHERE contact_id = %1 A...", (Array:3), TRUE)
#4 /var/www/html/CLIENTNAME/drupal-7.58/sites/CLIENTSITE.COM/civicrm_extensions/stripe/CRM/Stripe/Customer.php(35): CRM_Core_DAO::singleValueQuery("SELECT id\n FROM civicrm_stripe_customers\n WHERE contact_id = %1 A...", (Array:3))
#5 /var/www/html/CLIENTNAME/drupal-7.58/sites/CLIENTSITE.COM/civicrm_extensions/stripe/CRM/Core/Payment/Stripe.php(451): CRM_Stripe_Customer::find((Array:5))
#6 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Contribute/Form/Contribution/Confirm.php(1649): CRM_Core_Payment_Stripe->doPayment((Array:59), "contribute")
#7 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Contribute/Form/Contribution/Confirm.php(1405): CRM_Contribute_Form_Contribution_Confirm->postProcessMembership((Array:63), "2", Object(CRM_Contribute_Form_Contribution_Confirm), (Array:39), (Array:0), (Array:0), (Array:13), (Array:1), TRUE, NULL, FALSE, "5", (Array:1), TRUE)
#8 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Contribute/Form/Contribution/Confirm.php(2429): CRM_Contribute_Form_Contribution_Confirm->processMembership((Array:51), "2", (Array:0), (Array:0), (Array:39), (Array:1))
#9 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Contribute/Form/Contribution/Confirm.php(2304): CRM_Contribute_Form_Contribution_Confirm->doMembershipProcessing("2", (Array:51), (Array:39), (Array:1))
#10 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Contribute/Form/Contribution/Confirm.php(722): CRM_Contribute_Form_Contribution_Confirm->processFormSubmission("2")
#11 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Core/Form.php(489): CRM_Contribute_Form_Contribution_Confirm->postProcess()
#12 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Core/StateMachine.php(160): CRM_Core_Form->mainProcess()
#13 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Core/QuickForm/Action/Next.php(61): CRM_Core_StateMachine->perform(Object(CRM_Contribute_Form_Contribution_Confirm), "next", "Next")
#14 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/packages/HTML/QuickForm/Controller.php(203): CRM_Core_QuickForm_Action_Next->perform(Object(CRM_Contribute_Form_Contribution_Confirm), "next")
#15 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/packages/HTML/QuickForm/Page.php(103): HTML_QuickForm_Controller->handle(Object(CRM_Contribute_Form_Contribution_Confirm), "next")
#16 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Core/Controller.php(351): HTML_QuickForm_Page->handle("next")
#17 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Core/Invoke.php(309): CRM_Core_Controller->run((Array:3), NULL)
#18 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Core/Invoke.php(84): CRM_Core_Invoke::runItem((Array:15))
#19 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/CRM/Core/Invoke.php(52): CRM_Core_Invoke::_invoke((Array:3))
#20 /var/www/html/CLIENTNAME/drupal-7.58/sites/all/modules/civicrm/drupal/civicrm.module(445): CRM_Core_Invoke::invoke((Array:3))
#21 /var/www/html/CLIENTNAME/drupal-7.58/includes/menu.inc(527): civicrm_invoke("contribute", "transact")
#22 /var/www/html/CLIENTNAME/drupal-7.58/index.php(21): menu_execute_active_handler()
#23 {main}
I debugged this a little bit, and to avoid this error (on the test page for Contribution pages), I added this quick check in /CRM/Stripe/Customer.php:24:
if($params['is_live'] == 0 || $params['is_live'] == FALSE)
$params['is_live'] = 0;
Not sure why this is an issue, but this seems to do a temp fix... onto the next issue.
Failed to create Stripe Customer: Payment Response:
Type: invalid_request_error
Code: resource_missing
Message: No such token: Stripe Token
I'm not exactly sure what causes this issue.. but it seems Card
is set as "Stripe Token"? Is this correct?
The details I'm plugging in are: Card: 4000008260000000 CVV: 123 Expiry: anything valid (12/2020)
Any advice would be greatly appreciated!
Cheers, Reece