File tree Expand file tree Collapse file tree 2 files changed +7
-27
lines changed Expand file tree Collapse file tree 2 files changed +7
-27
lines changed Original file line number Diff line number Diff line change 17
17
"minimum-stability" : " dev" ,
18
18
"prefer-stable" : true ,
19
19
"autoload" : {
20
- "psr-4" : {"" : " src/" },
20
+ "psr-4" : {
21
+ "" : " src/"
22
+ },
21
23
"files" : [ " db-command.php" ]
22
24
},
23
- "require" : {
24
- "wp-cli/wp-cli" : " *"
25
- },
25
+ "require" : {},
26
26
"require-dev" : {
27
- "behat/behat" : " ~2.5"
27
+ "behat/behat" : " ~2.5" ,
28
+ "wp-cli/wp-cli" : " ^1.5"
28
29
},
29
30
"extra" : {
30
31
"branch-alias" : {
Original file line number Diff line number Diff line change @@ -950,7 +950,7 @@ public function search( $args, $assoc_args ) {
950
950
}
951
951
} else {
952
952
$ search_regex = '# ' . preg_quote ( $ search , '# ' ) . '#i ' ;
953
- $ esc_like_search = '% ' . self :: esc_like ( $ search ) . '% ' ;
953
+ $ esc_like_search = '% ' . Utils \ esc_like ( $ search ) . '% ' ;
954
954
}
955
955
956
956
$ encoding = null ;
@@ -1179,27 +1179,6 @@ private static function is_text_col( $type ) {
1179
1179
return false ;
1180
1180
}
1181
1181
1182
- /**
1183
- * Escapes a MySQL string for inclusion in a `LIKE` clause. BC wrapper around different WP versions of this.
1184
- *
1185
- * @param string $old String to escape.
1186
- * @param string Escaped string.
1187
- */
1188
- private static function esc_like ( $ old ) {
1189
- global $ wpdb ;
1190
-
1191
- // Remove notices in 4.0 and support backwards compatibility
1192
- if ( method_exists ( $ wpdb , 'esc_like ' ) ) {
1193
- // 4.0
1194
- $ old = $ wpdb ->esc_like ( $ old );
1195
- } else {
1196
- // 3.9 or less
1197
- $ old = like_escape ( esc_sql ( $ old ) );
1198
- }
1199
-
1200
- return $ old ;
1201
- }
1202
-
1203
1182
/**
1204
1183
* Escapes (backticks) MySQL identifiers (aka schema object names) - i.e. column names, table names, and database/index/alias/view etc names.
1205
1184
* See https://dev.mysql.com/doc/refman/5.5/en/identifiers.html
You can’t perform that action at this time.
0 commit comments