Compare commits

..

No commits in common. "c30deeed4911f531cab49815b077a43ca579fc3d" and "a832635a21d60a276bb35ed1c6dca2c366cb7d2c" have entirely different histories.

2 changed files with 2 additions and 6 deletions

View File

@ -15,10 +15,7 @@ public class ChatMessage : Phase2Task
public override async Task<Tuple<TaskStatus, WorkOrder>> ActOn(WorkOrder workOrder) public override async Task<Tuple<TaskStatus, WorkOrder>> ActOn(WorkOrder workOrder)
{ {
await Process.Start(ChatScript, await Process.Start(ChatScript,
workOrder.data["chatmessage"] + workOrder.data["chatmessage"] + (await TtrssClient.GetArticles(workOrder.articleId)).First().feed_title
(await TtrssClient.GetArticles(workOrder.articleId)).First().feed_title +
"; " +
(await TtrssClient.GetArticles(workOrder.articleId)).First().title
).WaitForExitAsync(); ).WaitForExitAsync();
return new Tuple<TaskStatus, WorkOrder>(TaskStatus.Done, workOrder); return new Tuple<TaskStatus, WorkOrder>(TaskStatus.Done, workOrder);
} }

View File

@ -25,7 +25,6 @@ namespace ttrss_co_client.tasks
var extensionUpstream = attachmentLink.Substring(attachmentLink.LastIndexOf('.')); var extensionUpstream = attachmentLink.Substring(attachmentLink.LastIndexOf('.'));
var downloadPath = Path.Combine(workingFolder, headline.title) + extensionUpstream; var downloadPath = Path.Combine(workingFolder, headline.title) + extensionUpstream;
var downloader = new HttpClient(); var downloader = new HttpClient();
downloader.DefaultRequestHeaders.UserAgent.ParseAdd("Mozilla/5.0 (compatible; AcmeInc/1.0)");
sw.Start(); sw.Start();
var dlResult = (await downloader.GetAsync(attachmentLink)); var dlResult = (await downloader.GetAsync(attachmentLink));
File.WriteAllBytes(downloadPath, await dlResult.Content.ReadAsByteArrayAsync()); File.WriteAllBytes(downloadPath, await dlResult.Content.ReadAsByteArrayAsync());