Merge pull request #10298 from Mangesh-Khairnar/fix-google-contacts-isse

fix(google-contact): remove parent kwarg from create contact
This commit is contained in:
mergify[bot] 2020-05-13 17:33:13 +00:00 committed by GitHub
commit 41d0d22edc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -218,7 +218,7 @@ def insert_contacts_to_google_contacts(doc, method=None):
emailAddresses = [{"value": email_id.email_id} for email_id in doc.email_ids]
try:
contact = google_contacts.people().createContact(parent='people/me', body={"names": [names],"phoneNumbers": phoneNumbers,
contact = google_contacts.people().createContact(body={"names": [names],"phoneNumbers": phoneNumbers,
"emailAddresses": emailAddresses}).execute()
frappe.db.set_value("Contact", doc.name, "google_contacts_id", contact.get("resourceName"))
except HttpError as err: