| @@ -93,25 +93,5 @@ | ||
| 93 | 93 | $instructions .= '<p>' . __( 'Your tax-deductible donation is greatly appreciated!', 'suredonation' ) . '</p>'; |
| 94 | 94 | |
| 95 | 95 | return $instructions; |
| 96 | 96 | } |
| 97 | - | |
| 98 | - /** | |
| 99 | - * Determine whether an instructions value is effectively blank. | |
| 100 | - * | |
| 101 | - * A cleared WYSIWYG editor serializes as empty markup (e.g. <p> </p> or | |
| 102 | - * <p><br></p>) rather than an empty string, so a plain trim() would treat it | |
| 103 | - * as non-blank. Strip tags and non-breaking spaces before checking. | |
| 104 | - * | |
| 105 | - * @param mixed $instructions Raw instructions value. | |
| 106 | - * @return bool True when the value has no meaningful content. | |
| 107 | - * @since 1.1.2 | |
| 108 | - */ | |
| 109 | - public static function is_blank_instructions( $instructions ) { | |
| 110 | - if ( ! is_string( $instructions ) ) { | |
| 111 | - return true; | |
| 112 | - } | |
| 113 | - | |
| 114 | - $plain = str_replace( [ ' ', "\xc2\xa0" ], ' ', $instructions ); | |
| 115 | - return '' === trim( wp_strip_all_tags( $plain ) ); | |
| 116 | - } | |
| 117 | 97 | } |