@@ -22,7 +22,7 @@ class Sanitize {
22
22
*/
23
23
public static function url_list ( $ value ) {
24
24
if ( ! \is_array ( $ value ) ) {
25
- $ value = \explode ( PHP_EOL , $ value );
25
+ $ value = \explode ( PHP_EOL , ( string ) $ value );
26
26
}
27
27
28
28
$ value = \array_filter ( $ value );
@@ -45,7 +45,7 @@ public static function url_list( $value ) {
45
45
*/
46
46
public static function identifier_list ( $ value ) {
47
47
if ( ! \is_array ( $ value ) ) {
48
- $ value = \explode ( PHP_EOL , $ value );
48
+ $ value = \explode ( PHP_EOL , ( string ) $ value );
49
49
}
50
50
51
51
$ value = \array_filter ( $ value );
@@ -84,7 +84,7 @@ public static function identifier_list( $value ) {
84
84
* @return string The sanitized list of hosts.
85
85
*/
86
86
public static function host_list ( $ value ) {
87
- $ value = \explode ( PHP_EOL , $ value );
87
+ $ value = \explode ( PHP_EOL , ( string ) $ value );
88
88
$ value = \array_map (
89
89
function ( $ host ) {
90
90
$ host = \trim ( $ host );
@@ -113,7 +113,7 @@ function ( $host ) {
113
113
*/
114
114
public static function blog_identifier ( $ value ) {
115
115
// Hack to allow dots in the username.
116
- $ parts = \explode ( '. ' , $ value );
116
+ $ parts = \explode ( '. ' , ( string ) $ value );
117
117
$ sanitized = \array_map ( 'sanitize_title ' , $ parts );
118
118
$ sanitized = \implode ( '. ' , $ sanitized );
119
119
0 commit comments