Deprecation notice for based meme removal

See commit 261ac08985
This commit is contained in:
Jordan Dominion
2023-08-15 18:53:27 -04:00
parent 97659bc01d
commit 29f5e87773
6 changed files with 8 additions and 7 deletions
@@ -22,6 +22,7 @@ namespace Tgstation.Server.Api.Models
/// <summary>
/// <see cref="bool"/> to enable based mode. Will auto reply with a youtube link to a video that says "based on the hardware that's installed in it" to anyone saying 'based on what?' case-insensitive.
/// </summary>
[Obsolete("Will be removed in next major TGS version")]
public bool BasedMeme { get; set; }
/// <summary>
@@ -39,7 +40,6 @@ namespace Tgstation.Server.Api.Models
/// </summary>
public DiscordConnectionStringBuilder()
{
BasedMeme = true;
}
/// <summary>
@@ -60,9 +60,10 @@ namespace Tgstation.Server.Api.Models
DMOutputDisplay = dMOutputDisplayType;
if (splits.Length > 2 && Int32.TryParse(splits[2], out Int32 basedMeme))
#pragma warning disable CS0618 // Type or member is obsolete
BasedMeme = Convert.ToBoolean(basedMeme);
else
BasedMeme = true; // oranges said this needs to be true by default :pensive:
BasedMeme = false; // oranges said this needs to be true by default :pensive:
if (splits.Length > 3 && Int32.TryParse(splits[3], out Int32 branding))
DeploymentBranding = Convert.ToBoolean(branding);
@@ -72,5 +73,6 @@ namespace Tgstation.Server.Api.Models
/// <inheritdoc />
public override string ToString() => $"{BotToken};{(int)DMOutputDisplay};{Convert.ToInt32(BasedMeme)};{Convert.ToInt32(DeploymentBranding)}";
#pragma warning restore CS0618 // Type or member is obsolete
}
}
@@ -199,7 +199,9 @@ namespace Tgstation.Server.Host.Components.Chat.Providers
var csb = new DiscordConnectionStringBuilder(chatBot.ConnectionString);
var botToken = csb.BotToken;
#pragma warning disable CS0618 // Type or member is obsolete
basedMeme = csb.BasedMeme;
#pragma warning restore CS0618 // Type or member is obsolete
outputDisplayType = csb.DMOutputDisplay;
deploymentBranding = csb.DeploymentBranding;