5228a2eb6c
* add an updator * change update branch * make updater work * change update branch * make work * add new line * add exception log + clean up
25 lines
628 B
C#
25 lines
628 B
C#
using System;
|
|
using System.Threading.Tasks;
|
|
using Newtonsoft.Json;
|
|
|
|
namespace DutyContent
|
|
{
|
|
internal class Updater
|
|
{
|
|
internal static void CheckNewVersion()
|
|
{
|
|
Task.Factory.StartNew(() =>
|
|
{
|
|
try
|
|
{
|
|
var json = WebApi.Request($"https://raw.githubusercontent.com/kshman/DutyContent/main/Data/DcDuty-{DcContent.Language}.json");
|
|
DcContent.Fill(json);
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
MesgLog.Ex(ex, 31);
|
|
}
|
|
});
|
|
}
|
|
}
|
|
}
|