Added startup confirmation to inform the user about selfbots violating discord tos

This commit is contained in:
Serraniel 2018-08-29 22:55:01 +02:00
parent 145a5eb0ca
commit a85aa1f96c
Signed by untrusted user who does not match committer: Serraniel
GPG key ID: 3690B4E7364525D3
2 changed files with 14 additions and 2 deletions

View file

@ -82,7 +82,6 @@ namespace DML.Application.Classes
Logger.Trace("Created log folder."); Logger.Trace("Created log folder.");
} }
var logFile = Path.Combine(logFolder, var logFile = Path.Combine(logFolder,
SweetUtils.LegalizeFilename($"{DateTime.Now.ToString(CultureInfo.CurrentCulture.DateTimeFormat.SortableDateTimePattern)}.log.zip")); SweetUtils.LegalizeFilename($"{DateTime.Now.ToString(CultureInfo.CurrentCulture.DateTimeFormat.SortableDateTimePattern)}.log.zip"));
@ -109,6 +108,18 @@ namespace DML.Application.Classes
Settings.Store(); Settings.Store();
} }
if (Settings.ShowStartUpHints)
{
if (MessageBox.Show(splash, "This tool is considered as a selfbot which may violate the Discord TOS. By using this tool you take the risk to get your account banned. Although this never happened yet (as far as I know) you have to confirm to this.\n\r\n\rDo you wish to continue?", "HOLD UP!!", MessageBoxButtons.YesNo) != DialogResult.Yes)
{
splash.Close();
return;
}
Settings.ShowStartUpHints = false;
Settings.Store();
}
Logger.Debug("Loading jobs collection out of database..."); Logger.Debug("Loading jobs collection out of database...");
Scheduler.JobList = Job.RestoreJobs().ToList(); Scheduler.JobList = Job.RestoreJobs().ToList();
@ -175,7 +186,7 @@ namespace DML.Application.Classes
if (!string.IsNullOrEmpty(Settings.LoginToken)) if (!string.IsNullOrEmpty(Settings.LoginToken))
{ {
Logger.Debug("Trying to login with last known token..."); Logger.Debug("Trying to login with last known token...");
loggedIn= await DMLClient.Login(Settings.LoginToken); loggedIn = await DMLClient.Login(Settings.LoginToken);
} }
if (!loggedIn) if (!loggedIn)

View file

@ -15,6 +15,7 @@ namespace DML.Application.Classes
public string FileNameScheme { get; set; } = @"%guild%\%channel%\%id%"; public string FileNameScheme { get; set; } = @"%guild%\%channel%\%id%";
public bool SkipExistingFiles { get; set; } = true; public bool SkipExistingFiles { get; set; } = true;
public int ThreadLimit { get; set; } = 50; public int ThreadLimit { get; set; } = 50;
public bool ShowStartUpHints { get; set; } = true;
public void Store() public void Store()
{ {