File tree Expand file tree Collapse file tree 1 file changed +36
-36
lines changed Expand file tree Collapse file tree 1 file changed +36
-36
lines changed Original file line number Diff line number Diff line change @@ -12,48 +12,48 @@ class Find_Command {
12
12
*/
13
13
private $ ignored_paths = [
14
14
// System directories
15
- '/ __MACOSX/ ' ,
15
+ '__MACOSX/ ' ,
16
16
// Webserver directories
17
- '/ cache/ ' ,
18
- '/ caches/ ' ,
19
- '/ logs/ ' ,
20
- '/ debuglogs/ ' ,
21
- '/ Maildir/ ' ,
22
- '/ tmp/ ' ,
17
+ 'cache/ ' ,
18
+ 'caches/ ' ,
19
+ 'logs/ ' ,
20
+ 'debuglogs/ ' ,
21
+ 'Maildir/ ' ,
22
+ 'tmp/ ' ,
23
23
// Generic application directories
24
- '/ configs/ ' ,
25
- '/ config/ ' ,
26
- '/ data/ ' ,
27
- '/ uploads/ ' ,
28
- '/ themes/ ' ,
29
- '/ plugins/ ' ,
30
- '/ modules/ ' ,
31
- '/ assets/ ' ,
32
- '/ thumbs/ ' ,
33
- '/ thumb/ ' ,
34
- '/ albums/ ' ,
35
- '/ attachments/ ' ,
36
- '/ js/ ' ,
37
- '/ pdf/ ' ,
38
- '/ releases/ ' ,
39
- '/ filestore/ ' ,
24
+ 'configs/ ' ,
25
+ 'config/ ' ,
26
+ 'data/ ' ,
27
+ 'uploads/ ' ,
28
+ 'themes/ ' ,
29
+ 'plugins/ ' ,
30
+ 'modules/ ' ,
31
+ 'assets/ ' ,
32
+ 'thumbs/ ' ,
33
+ 'thumb/ ' ,
34
+ 'albums/ ' ,
35
+ 'attachments/ ' ,
36
+ 'js/ ' ,
37
+ 'pdf/ ' ,
38
+ 'releases/ ' ,
39
+ 'filestore/ ' ,
40
40
// Backup directories
41
- '/ backup/ ' ,
42
- '/ backups/ ' ,
43
- '/ mysql_backups/ ' ,
44
- '/ updater_backup/ ' ,
41
+ 'backup/ ' ,
42
+ 'backups/ ' ,
43
+ 'mysql_backups/ ' ,
44
+ 'updater_backup/ ' ,
45
45
// Other applications
46
- '/ owncloud/ ' ,
46
+ 'owncloud/ ' ,
47
47
// Dependency management
48
- '/ node_modules/ ' ,
49
- '/ bower_components/ ' ,
50
- '/ vendor/ ' ,
51
- '/ svn/ ' ,
48
+ 'node_modules/ ' ,
49
+ 'bower_components/ ' ,
50
+ 'vendor/ ' ,
51
+ 'svn/ ' ,
52
52
// Directory for a common script kiddie hack
53
- '/ coockies/ ' ,
53
+ 'coockies/ ' ,
54
54
// Already in a WordPress install
55
- '/ wp-admin/ ' ,
56
- '/ wp-content/ ' ,
55
+ 'wp-admin/ ' ,
56
+ 'wp-content/ ' ,
57
57
];
58
58
59
59
/**
@@ -252,7 +252,7 @@ private function recurse_directory( $path ) {
252
252
253
253
// This looks like a wp-includes directory, so check if it has a
254
254
// version.php file.
255
- if ( ' / wp-includes/ ' === substr ( $ path , -13 )
255
+ if ( DIRECTORY_SEPARATOR . ' wp-includes/ ' === substr ( $ path , -13 )
256
256
&& file_exists ( $ path . 'version.php ' ) ) {
257
257
$ version_path = $ path . 'version.php ' ;
258
258
$ wp_path = substr ( $ path , 0 , -13 );
You can’t perform that action at this time.
0 commit comments