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

Jetpack: Stats: Fix csv trailing newline handling #39787

Merged
merged 1 commit into from
Oct 16, 2024

Commits on Oct 16, 2024

  1. Jetpack: Stats: Fix csv trailing newline handling

    When #39665 switched from incorrectly using `str_getcsv( $csv, "\n" )`
    to `explode()`, a minor difference between the two was unnoticed: the
    former does not produce an empty element at the end of the result on a
    trailing newline, while the latter does.
    
    Add an `rtrim` on the data to ensure there isn't a trailing newline.
    anomiex committed Oct 16, 2024
    Configuration menu
    Copy the full SHA
    d9c5b01 View commit details
    Browse the repository at this point in the history