Ticket #46840: 46840-2.patch
File 46840-2.patch, 7.2 KB (added by , 6 years ago) |
---|
-
wp-admin/includes/class-wp-filesystem-base.php
89 89 * @since 2.7.0 90 90 * 91 91 * @param string $theme The Theme stylesheet or template for the directory. 92 * @return string The location of the remote path.92 * @return string|false The location of the remote path. 93 93 */ 94 94 public function wp_themes_dir( $theme = false ) { 95 95 $theme_root = get_theme_root( $theme ); … … 267 267 /* 268 268 * Working from /home/ to /user/ to /wordpress/ see if that file exists within 269 269 * the current folder, If it's found, change into it and follow through looking 270 * for it. If it can t find WordPress down that route, it'll continue onto the next270 * for it. If it can't find WordPress down that route, it'll continue onto the next 271 271 * folder level, and see if that matches, and so on. If it reaches the end, and still 272 * can t find it, it'll return false for the entire function.272 * can't find it, it'll return false for the entire function. 273 273 */ 274 274 if ( isset( $files[ $key ] ) ) { 275 275 … … 544 544 * @abstract 545 545 * 546 546 * @param string $file Path to the file. 547 * @param int $mode Optional. The permissions as octal number, usually 0644 for files, 0755 for dirs.547 * @param int|false $mode Optional. The permissions as octal number, usually 0644 for files, 0755 for dirs. 548 548 * @param bool $recursive Optional. If set True changes file group recursively. Defaults to False. 549 549 * @return bool|string 550 550 */ … … 588 588 * @param string $destination Path to the destination file. 589 589 * @param bool $overwrite Optional. Whether to overwrite the destination file if it exists. 590 590 * Default false. 591 * @param int $mode Optional. The permissions as octal number, usually 0644 for files, 0755 for dirs.591 * @param int|false $mode Optional. The permissions as octal number, usually 0644 for files, 0755 for dirs. 592 592 * Default false. 593 593 * @return bool True if file copied successfully, False otherwise. 594 594 */ -
wp-admin/includes/class-wp-filesystem-direct.php
50 50 * 51 51 * @param string $file Remote path to the file where to write the data. 52 52 * @param string $contents The data to write. 53 * @param int $mode Optional. The file permissions as octal number, usually 0644.53 * @param int|false $mode Optional. The file permissions as octal number, usually 0644. 54 54 * Default false. 55 55 * @return bool False upon failure, true otherwise. 56 56 */ … … 130 130 * Changes filesystem permissions 131 131 * 132 132 * @param string $file Path to the file. 133 * @param int $mode Optional. The permissions as octal number, usually 0644 for files,133 * @param int|false $mode Optional. The permissions as octal number, usually 0644 for files, 134 134 * 0755 for dirs. Default false. 135 135 * @param bool $recursive Optional. If set True changes file group recursively. Default false. 136 136 * @return bool Returns true on success or false on failure. … … 236 236 * @param string $source 237 237 * @param string $destination 238 238 * @param bool $overwrite 239 * @param int $mode239 * @param int|false $mode 240 240 * @return bool 241 241 */ 242 242 public function copy( $source, $destination, $overwrite = false, $mode = false ) { -
wp-admin/includes/class-wp-filesystem-ftpext.php
156 156 /** 157 157 * @param string $file 158 158 * @param string $contents 159 * @param bool|int$mode159 * @param int|false $mode 160 160 * @return bool 161 161 */ 162 162 public function put_contents( $file, $contents, $mode = false ) { … … 214 214 215 215 /** 216 216 * @param string $file 217 * @param int $mode217 * @param int|false $mode 218 218 * @param bool $recursive 219 219 * @return bool 220 220 */ … … 274 274 * @param string $source 275 275 * @param string $destination 276 276 * @param bool $overwrite 277 * @param string|bool$mode277 * @param int|false $mode 278 278 * @return bool 279 279 */ 280 280 public function copy( $source, $destination, $overwrite = false, $mode = false ) { … … 537 537 } 538 538 539 539 $pwd = @ftp_pwd( $this->link ); 540 if ( ! @ftp_chdir( $this->link, $path ) ) { // Can t change to folder = folder doesn't exist540 if ( ! @ftp_chdir( $this->link, $path ) ) { // Can't change to folder = folder doesn't exist 541 541 return false; 542 542 } 543 543 $list = @ftp_rawlist( $this->link, '-a', false ); -
wp-admin/includes/class-wp-filesystem-ftpsockets.php
167 167 /** 168 168 * @param string $file 169 169 * @param string $contents 170 * @param int| bool$mode170 * @param int|false $mode 171 171 * @return bool 172 172 */ 173 173 public function put_contents( $file, $contents, $mode = false ) { … … 225 225 226 226 /** 227 227 * @param string $file 228 * @param int| bool$mode228 * @param int|false $mode 229 229 * @param bool $recursive 230 230 * @return bool 231 231 */ … … 283 283 * @param string $source 284 284 * @param string $destination 285 285 * @param bool $overwrite 286 * @param int| bool$mode286 * @param int|false $mode 287 287 * @return bool 288 288 */ 289 289 public function copy( $source, $destination, $overwrite = false, $mode = false ) { -
wp-admin/includes/class-wp-filesystem-ssh2.php
246 246 /** 247 247 * @param string $file 248 248 * @param string $contents 249 * @param bool|int$mode249 * @param int|false $mode 250 250 * @return bool 251 251 */ 252 252 public function put_contents( $file, $contents, $mode = false ) { … … 299 299 300 300 /** 301 301 * @param string $file 302 * @param int 302 * @param int|false $mode 303 303 * @param bool $recursive 304 304 * @return bool|string 305 305 */ … … 329 329 * 330 330 * @param string $file Path to the file. 331 331 * @param string|int $owner A user name or number. 332 * @param bool $recursive Optional. If set True changes file owner recursiv ly. Default False.332 * @param bool $recursive Optional. If set True changes file owner recursively. Default False. 333 333 * @return bool True on success or false on failure. 334 334 */ 335 335 public function chown( $file, $owner, $recursive = false ) { … … 386 386 * @param string $source 387 387 * @param string $destination 388 388 * @param bool $overwrite 389 * @param int| bool$mode389 * @param int|false $mode 390 390 * @return bool 391 391 */ 392 392 public function copy( $source, $destination, $overwrite = false, $mode = false ) {