Skip to content

Commit

Permalink
- Fix build error
Browse files Browse the repository at this point in the history
  • Loading branch information
KoalaBear84 committed Jul 13, 2020
1 parent b26bd0e commit 700f771
Showing 1 changed file with 12 additions and 16 deletions.
28 changes: 12 additions & 16 deletions OpenDirectoryDownloader/OpenDirectoryIndexer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ public async void StartIndexingAsync()
string serverInfo = await FtpParser.GetFtpServerInfo(Session.Root, OpenDirectoryIndexerSettings.Username, OpenDirectoryIndexerSettings.Password);

if (string.IsNullOrWhiteSpace(serverInfo))
{
{
serverInfo = "Failed or no server info available.";
}

Expand Down Expand Up @@ -292,16 +292,16 @@ public async void StartIndexingAsync()

try
{
//UploadFilesFile uploadFilesFile = await UploadFileIo.UploadFile(HttpClient, urlsPath);
//HistoryLogger.Info($"uploadfiles.io: {JsonConvert.SerializeObject(uploadFilesFile)}");
//Session.UploadedUrlsUrl = uploadFilesFile.Url.ToString();
//UploadFilesFile uploadFilesFile = await UploadFileIo.UploadFile(HttpClient, urlsPath);
//HistoryLogger.Info($"uploadfiles.io: {JsonConvert.SerializeObject(uploadFilesFile)}");
//Session.UploadedUrlsUrl = uploadFilesFile.Url.ToString();

GoFilesFile uploadedFile = await GoFileIo.UploadFile(HttpClient, urlsPath);
HistoryLogger.Info($"goFile.io: {JsonConvert.SerializeObject(uploadedFile)}");
Session.UploadedUrlsUrl = uploadedFile.Url.ToString();
GoFilesFile uploadedFile = await GoFileIo.UploadFile(HttpClient, urlsPath);
HistoryLogger.Info($"goFile.io: {JsonConvert.SerializeObject(uploadedFile)}");
Session.UploadedUrlsUrl = uploadedFile.Url.ToString();

Console.WriteLine($"Uploaded URLs: {Session.UploadedUrlsUrl}");
}
Console.WriteLine($"Uploaded URLs: {Session.UploadedUrlsUrl}");
}
catch (Exception ex)
{
Logger.Warn($"Error uploading URLs: {ex.Message}");
Expand Down Expand Up @@ -336,8 +336,8 @@ public async void StartIndexingAsync()

if (Session.SpeedtestResult != null)
{
Console.WriteLine($"Finished speedtest. Downloaded: {FileSizeHelper.ToHumanReadable(Session.SpeedtestResult.DownloadedBytes)}, Time: {Session.SpeedtestResult.ElapsedMiliseconds / 1000:F1} s, Speed: {Session.SpeedtestResult.MaxMBsPerSecond:F1} MB/s ({Session.SpeedtestResult.MaxMBsPerSecond * 8:F0} mbit)");
}
Console.WriteLine($"Finished speedtest. Downloaded: {FileSizeHelper.ToHumanReadable(Session.SpeedtestResult.DownloadedBytes)}, Time: {Session.SpeedtestResult.ElapsedMiliseconds / 1000:F1} s, Speed: {Session.SpeedtestResult.MaxMBsPerSecond:F1} MB/s ({Session.SpeedtestResult.MaxMBsPerSecond * 8:F0} mbit)");
}
}
catch (Exception ex)
{
Expand Down Expand Up @@ -475,13 +475,9 @@ private async Task WebDirectoryProcessor(ConcurrentQueue<WebDirectory> queue, st
if (Session.Root.Uri.Scheme == Constants.UriScheme.Ftp || Session.Root.Uri.Scheme == Constants.UriScheme.Ftps)
{
WebDirectory parsedWebDirectory = await FtpParser.ParseFtpAsync(name, webDirectory, OpenDirectoryIndexerSettings.Username, OpenDirectoryIndexerSettings.Password);

{
WebDirectory parsedWebDirectory = await FtpParser.ParseFtpAsync(name, webDirectory);
AddProcessedWebDirectory(webDirectory, parsedWebDirectory);
}
else
if (Session.Root.Uri.Host == Constants.GoogleDriveDomain)
else if (Session.Root.Uri.Host == Constants.GoogleDriveDomain)
{
string baseUrl = webDirectory.Url;

Expand Down

0 comments on commit 700f771

Please sign in to comment.