Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Fix escaping linter errors #2296
Fixes escaping violations reported by PHPCS.
Note that I used
This PR has the potential to break pretty much everything on the backend and the frontend, so careful testing is required. We should try to get this merged as soon as possible to avoid rebasing future PRs, and so that we can work from this version and watch for issues.
Alright, I haven't made it through the whole thing yet, but I wanted to leave the notes that I have so far. I've walked through the diff and stopped at
includes/class-sensei-learners-main.php. I'll continue from there in my next review.
I have a few comments. A bunch of them are lines that hand an array into
wp_kses_post as the first argument. This seems to work fine because of implementation details of those functions, but the documentation states that the first parameter should be a string. I feel like handing in an array might be an unsupported pattern that we should avoid? Or maybe it's a common practice that just isn't reflected in the documentation, in which case feel free to disregard these comments
Not a blocker, but it might be good to create a function for applying
wp_kses_post to all of the elements in an array, rather than having that code duplicated.
Gotta run for a bit, but I'm getting closer. Wanted to give you my current set of comments. I stopped at
includes/class-sensei-list-table.php and will continue when I get back.