/** * Returns the last modified time of the given file. * Return -1 on error * * @param string $remoteFile * @param string|null $format * * @return int */ public function modifiedTime($remoteFile, $format = null) { $time = $this->ftp->mdtm($remoteFile); if ($time !== -1 && $format !== null) { return date($format, $time); } return $time; }