Preparing a fix for TODO (wip)
This commit is contained in:
		
					parent
					
						
							
								cda241893b
							
						
					
				
			
			
				commit
				
					
						3e95a389bb
					
				
			
		
					 1 changed files with 15 additions and 8 deletions
				
			
		|  | @ -140,14 +140,21 @@ def handle_webhook(request): | ||||||
|                 logger.error(str(ex)) |                 logger.error(str(ex)) | ||||||
|             if ho: |             if ho: | ||||||
|                 logger.debug("Create a VM for order %s" % str(ho)) |                 logger.debug("Create a VM for order %s" % str(ho)) | ||||||
| 
 |                 # TODO: fix the error below | ||||||
|             # TODO: fix the error below |                 try: | ||||||
|             do_create_vm(request, user, stripe_api_cus_id, |                     user = {'name': ho.customer.user.name, | ||||||
|                          card_details_response, stripe_subscription_obj, |                             'email': ho.customer.user.email} | ||||||
|                          stripe_onetime_charge, gp_details, specs, |                     stripe_api_cus_id = ho.customer.stripe_id | ||||||
|                          vm_template_id, |                     stripe_subscription_obj = stripe.Subscription.retrieve(invoice_obj.subscription) | ||||||
|                          template |                     do_create_vm(request, user, stripe_api_cus_id, | ||||||
|                          ) |                                  card_details_response, | ||||||
|  |                                  stripe_subscription_obj, | ||||||
|  |                                  stripe_onetime_charge, gp_details, specs, | ||||||
|  |                                  vm_template_id, | ||||||
|  |                                  template | ||||||
|  |                                  ) | ||||||
|  |                 except Exception as ex: | ||||||
|  |                     logger.error(str(ex)) | ||||||
| 
 | 
 | ||||||
|     else: |     else: | ||||||
|         logger.error("Unhandled event : " + event.type) |         logger.error("Unhandled event : " + event.type) | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue