mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-10-04 22:57:20 +00:00
Coding Standards: Use strict comparison where strlen() is involved.
Follow-up to [649], [1345], [3034], [6132], [6314], [6974], [55642]. Props aristath, poena, afercia, SergeyBiryukov. See #57839. git-svn-id: https://develop.svn.wordpress.org/trunk@55652 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -42,7 +42,7 @@ function get_the_ID() { // phpcs:ignore WordPress.NamingConventions.ValidFunctio
|
||||
function the_title( $before = '', $after = '', $display = true ) {
|
||||
$title = get_the_title();
|
||||
|
||||
if ( strlen( $title ) == 0 ) {
|
||||
if ( strlen( $title ) === 0 ) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -88,7 +88,7 @@ function the_title_attribute( $args = '' ) {
|
||||
|
||||
$title = get_the_title( $parsed_args['post'] );
|
||||
|
||||
if ( strlen( $title ) == 0 ) {
|
||||
if ( strlen( $title ) === 0 ) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user