Wordpress 3.5
[autoinstalls/wordpress.git] / wp-admin / includes / class-wp-filesystem-ftpext.php
index 12280304721c792c4eb9888d981f2d21ccaf3437..d087189147ebe626040f01a3c9a14e977a1dd96e 100644 (file)
@@ -330,6 +330,10 @@ class WP_Filesystem_FTPext extends WP_Filesystem_Base {
                        }
                }
 
+               // Replace symlinks formatted as "source -> target" with just the source name
+               if ( $b['islink'] )
+                       $b['name'] = preg_replace( '/(\s*->\s*.*)$/', '', $b['name'] );
+
                return $b;
        }