Security update for Core, with self-updated composer
[yaffs-website] / web / core / lib / Drupal / Core / FileTransfer / FTPExtension.php
index c5f1b22b30d5644bb1a47a19b6e5c6284aed7121..99c1c0688125e738180c7e206a01153282e3e924 100644 (file)
@@ -45,7 +45,7 @@ class FTPExtension extends FTP implements ChmodInterface {
   protected function removeDirectoryJailed($directory) {
     $pwd = ftp_pwd($this->connection);
     if (!ftp_chdir($this->connection, $directory)) {
-      throw new FileTransferException("Unable to change to directory @directory", NULL, ['@directory' => $directory]);
+      throw new FileTransferException("Unable to change the current directory to @directory", NULL, ['@directory' => $directory]);
     }
     $list = @ftp_nlist($this->connection, '.');
     if (!$list) {
@@ -65,7 +65,7 @@ class FTPExtension extends FTP implements ChmodInterface {
     }
     ftp_chdir($this->connection, $pwd);
     if (!ftp_rmdir($this->connection, $directory)) {
-      throw new FileTransferException("Unable to remove to directory @directory", NULL, ['@directory' => $directory]);
+      throw new FileTransferException("Unable to remove the directory @directory", NULL, ['@directory' => $directory]);
     }
   }
 
@@ -74,7 +74,7 @@ class FTPExtension extends FTP implements ChmodInterface {
    */
   protected function removeFileJailed($destination) {
     if (!ftp_delete($this->connection, $destination)) {
-      throw new FileTransferException("Unable to remove to file @file", NULL, ['@file' => $destination]);
+      throw new FileTransferException("Unable to remove the file @file", NULL, ['@file' => $destination]);
     }
   }
 
@@ -108,7 +108,7 @@ class FTPExtension extends FTP implements ChmodInterface {
     if ($this->isDirectory($path) && $recursive) {
       $filelist = @ftp_nlist($this->connection, $path);
       if (!$filelist) {
-        //empty directory - returns false
+        // empty directory - returns false
         return;
       }
       foreach ($filelist as $file) {