CheckForNewChaptersWorker

This commit is contained in:
2025-07-03 20:11:18 +02:00
parent f6f5e21151
commit d6847d769e
4 changed files with 43 additions and 9 deletions

View File

@ -1,8 +1,6 @@
using System.Runtime.InteropServices;
using API.MangaDownloadClients;
using API.Schema.NotificationsContext;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
namespace API;
@ -50,6 +48,8 @@ public struct TrangaSettings()
};
public Dictionary<RequestType, int> RequestLimits { get; private set; } = DefaultRequestLimits;
public string DownloadLanguage { get; private set; } = "en";
public static TrangaSettings Load()
{
return JsonConvert.DeserializeObject<TrangaSettings>(File.ReadAllText(settingsFilePath));
@ -101,4 +101,10 @@ public struct TrangaSettings()
this.FlareSolverrUrl = url;
Save();
}
public void SetDownloadLanguage(string language)
{
this.DownloadLanguage = language;
Save();
}
}