public function getModifiedTimestamp(string $remoteFile, int $attempts = 1, int $sleepBetweenAttempts = 5)
    {
        $timestamp = @ftp_mdtm($this->ftp, $remoteFile);

        if ($timestamp < 0) {
            if (--$attempts > 0) {
                sleep($sleepBetweenAttempts);

                return $this->getModifiedTimestamp($remoteFile, $attempts, $sleepBetweenAttempts);
            }

            throw new Exception("Cannot get file modification timestamp");
        }

        return $timestamp;
    }