Make WordPress Core

Ticket #10522: file.php.patch

File file.php.patch, 923 bytes (added by ntm, 15 years ago)
  • file.php

     
    679679        $credentials['hostname'] = defined('FTP_HOST') ? FTP_HOST : (!empty($_POST['hostname']) ? $_POST['hostname'] : $credentials['hostname']);
    680680        $credentials['username'] = defined('FTP_USER') ? FTP_USER : (!empty($_POST['username']) ? $_POST['username'] : $credentials['username']);
    681681        $credentials['password'] = defined('FTP_PASS') ? FTP_PASS : (!empty($_POST['password']) ? $_POST['password'] : '');
     682        $credentials['connect_timeout'] = defined('FTP_CONNECT_TIMEOUT') ? FTP_CONNECT_TIMEOUT : (!empty($_POST['connect_timeout']) ? $_POST['connect_timeout'] : 5);
    682683
    683684        // Check to see if we are setting the public/private keys for ssh
    684685        $credentials['public_key'] = defined('FTP_PUBKEY') ? FTP_PUBKEY : (!empty($_POST['public_key']) ? $_POST['public_key'] : '');