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

ISSUE-140: WebformMetadataDate wrongly array filters empties #141

Merged
merged 2 commits into from
Aug 4, 2022
Merged

ISSUE-140: WebformMetadataDate wrongly array filters empties #141

merged 2 commits into from
Aug 4, 2022

Conversation

aksm
Copy link
Contributor

@aksm aksm commented Jun 9, 2022

Resolves #140

@DiegoPino Gave this a shot, but not sure I understood all about the issue so glad to make additional changes.

@aksm aksm added bug Something isn't working Webform Elements Things with input to fill and interact with while ingesting metadata labels Jun 9, 2022
@aksm aksm added this to the 1.0.0 milestone Jun 9, 2022
@aksm aksm requested a review from DiegoPino June 9, 2022 14:30
@aksm aksm self-assigned this Jun 9, 2022
Copy link
Member

@DiegoPino DiegoPino left a comment

Choose a reason for hiding this comment

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

The elseif condition is not (from my phone so fight me) in the right spot. Please test this again with data/let me know

}
}
foreach ($value as $item) {
$filtered_value = array_filter($item);
Copy link
Member

Choose a reason for hiding this comment

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

I think your elseif is in the wrong spot. Basically
On any array_filter filter operation we can do a is_array($value) ? array_filter…… : …..

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ok, took some doing to figure out what I was doing, but testing the below commit seems to get rid of the warning.

@DiegoPino DiegoPino merged commit d3a8123 into esmero:1.0.0 Aug 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Webform Elements Things with input to fill and interact with while ingesting metadata
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants