Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix against PHP warning; Notice: Array to string conversion #9753

Merged
merged 1 commit into from
Feb 1, 2017

Conversation

chanunc
Copy link
Contributor

@chanunc chanunc commented Jan 30, 2017

Change array comparing difference function to fix
the PHP warning message of Notice: Array to string conversion appear
when configure profile contain common field with contribution page.

@colemanw
Copy link
Member

@civicrm-builder add to whitelist

@colemanw
Copy link
Member

@chanunc can you please provide more steps to reproduce this bug? Ideally file an issue at https://issues.civicrm.org/jira/secure/CreateIssue!default.jspa

@chanunc
Copy link
Contributor Author

chanunc commented Jan 31, 2017

Yes, sure!
Steps to reproduce are in the ticket.
https://issues.civicrm.org/jira/browse/CRM-19949

Copy link
Contributor

@jitendrapurohit jitendrapurohit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

array_diff_assoc gives the notice error if any one of the values in the param array is also an array(recursive array) and it had to convert it to a string.

As we are only comparing the common fields, the name of which is present in keys, array_diff_key does the needful.

@monishdeb monishdeb merged commit 066122b into civicrm:master Feb 1, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants