WordPress/wp-includes/rest-api
Sergey Biryukov 32e94b4de1 Code Modernization: Use str_starts_with() and str_ends_with() in a few more places.
`str_starts_with()` and `str_ends_with()` were introduced in PHP 8.0 to perform a case-sensitive check indicating if the string to search in (haystack) begins or ends with the given substring (needle).

WordPress core includes a polyfill for these functions on PHP < 8.0 as of WordPress 5.9.

Follow-up to [55990], [56014].

See #58220.
Built from https://develop.svn.wordpress.org/trunk@56019


git-svn-id: http://core.svn.wordpress.org/trunk@55531 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2023-06-24 16:50:24 +00:00
..
endpoints Code Modernization: Use str_starts_with() and str_ends_with() in a few more places. 2023-06-24 16:50:24 +00:00
fields Code Modernization: Add AllowDynamicProperties attribute to all (parent) classes. 2022-09-12 15:47:14 +00:00
search Docs: Miscellaneous improvements and corrections to docblocks. 2023-02-07 21:21:18 +00:00
class-wp-rest-request.php Code Modernization: Replace usage of strpos() with str_contains(). 2023-06-22 14:36:26 +00:00
class-wp-rest-response.php Coding Standards: Always use parentheses when instantiating an object. 2022-11-29 15:51:14 +00:00
class-wp-rest-server.php Code Modernization: Replace usage of strpos() with str_starts_with(). 2023-05-02 15:45:22 +00:00