diff --git a/build/Version.props b/build/Version.props index e301751a07..c6b95d7f1a 100644 --- a/build/Version.props +++ b/build/Version.props @@ -5,9 +5,9 @@ 6.0.0 5.0.0 - 9.11.1 + 10.0.0 6.0.0 - 11.0.1 + 12.0.0 13.0.0 6.5.2 5.6.1 diff --git a/src/Tgstation.Server.Api/Models/DiscordConnectionStringBuilder.cs b/src/Tgstation.Server.Api/Models/DiscordConnectionStringBuilder.cs index c51d74a49f..7ab64442ce 100644 --- a/src/Tgstation.Server.Api/Models/DiscordConnectionStringBuilder.cs +++ b/src/Tgstation.Server.Api/Models/DiscordConnectionStringBuilder.cs @@ -19,11 +19,6 @@ namespace Tgstation.Server.Api.Models /// See https://discordapp.com/developers/docs/topics/oauth2#bots public string? BotToken { get; set; } - /// - /// 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. - /// - public bool BasedMeme { get; set; } - /// /// If the tgstation-server logo is shown in deployment embeds. /// @@ -34,12 +29,17 @@ namespace Tgstation.Server.Api.Models /// public DiscordDMOutputDisplayType DMOutputDisplay { get; set; } + /// + /// Currently unused. Note its origin in based meme before repurposing. + /// + readonly bool unusedFlag; + + /// /// Initializes a new instance of the class. /// public DiscordConnectionStringBuilder() { - BasedMeme = true; } /// @@ -60,9 +60,7 @@ namespace Tgstation.Server.Api.Models DMOutputDisplay = dMOutputDisplayType; if (splits.Length > 2 && Int32.TryParse(splits[2], out Int32 basedMeme)) - BasedMeme = Convert.ToBoolean(basedMeme); - else - BasedMeme = true; // oranges said this needs to be true by default :pensive: + unusedFlag = Convert.ToBoolean(basedMeme); if (splits.Length > 3 && Int32.TryParse(splits[3], out Int32 branding)) DeploymentBranding = Convert.ToBoolean(branding); @@ -71,6 +69,6 @@ namespace Tgstation.Server.Api.Models } /// - public override string ToString() => $"{BotToken};{(int)DMOutputDisplay};{Convert.ToInt32(BasedMeme)};{Convert.ToInt32(DeploymentBranding)}"; + public override string ToString() => $"{BotToken};{(int)DMOutputDisplay};{Convert.ToInt32(unusedFlag)};{Convert.ToInt32(DeploymentBranding)}"; } } diff --git a/src/Tgstation.Server.Host/Components/Chat/Providers/DiscordProvider.cs b/src/Tgstation.Server.Host/Components/Chat/Providers/DiscordProvider.cs index 142513c275..937105594d 100644 --- a/src/Tgstation.Server.Host/Components/Chat/Providers/DiscordProvider.cs +++ b/src/Tgstation.Server.Host/Components/Chat/Providers/DiscordProvider.cs @@ -82,11 +82,6 @@ namespace Tgstation.Server.Host.Components.Chat.Providers /// readonly object connectDisconnectLock; - /// - /// 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. - /// - readonly bool basedMeme; - /// /// If the tgstation-server logo is shown in deployment embeds. /// @@ -199,7 +194,6 @@ namespace Tgstation.Server.Host.Components.Chat.Providers var csb = new DiscordConnectionStringBuilder(chatBot.ConnectionString); var botToken = csb.BotToken; - basedMeme = csb.BasedMeme; outputDisplayType = csb.DMOutputDisplay; deploymentBranding = csb.DeploymentBranding; @@ -514,22 +508,6 @@ namespace Tgstation.Server.Host.Components.Chat.Providers FailIfNotExists = false, }; - if (basedMeme && messageCreateEvent.Content.Equals("Based on what?", StringComparison.OrdinalIgnoreCase)) - { - await SendMessage( - new DiscordMessage - { - MessageReference = messageReference, - }, - new MessageContent - { - Text = "https://youtu.be/LrNu-SuFF_o", - }, - messageCreateEvent.ChannelID.Value, - cancellationToken); - return Result.FromSuccess(); - } - var channelsClient = serviceProvider.GetRequiredService(); var channelResponse = await channelsClient.GetChannelAsync(messageCreateEvent.ChannelID, cancellationToken); if (!channelResponse.IsSuccess) diff --git a/tests/Tgstation.Server.Tests/Live/Instance/ChatTest.cs b/tests/Tgstation.Server.Tests/Live/Instance/ChatTest.cs index f90c1dc116..02faa835ca 100644 --- a/tests/Tgstation.Server.Tests/Live/Instance/ChatTest.cs +++ b/tests/Tgstation.Server.Tests/Live/Instance/ChatTest.cs @@ -149,7 +149,6 @@ namespace Tgstation.Server.Tests.Live.Instance // needs to just be valid connectionString = new DiscordConnectionStringBuilder { - BasedMeme = true, BotToken = "some_token", DeploymentBranding = true, DMOutputDisplay = DiscordDMOutputDisplayType.Never, diff --git a/tests/Tgstation.Server.Tests/Live/Instance/InstanceTest.cs b/tests/Tgstation.Server.Tests/Live/Instance/InstanceTest.cs index 3035e45de9..9265e0e7f6 100644 --- a/tests/Tgstation.Server.Tests/Live/Instance/InstanceTest.cs +++ b/tests/Tgstation.Server.Tests/Live/Instance/InstanceTest.cs @@ -97,7 +97,6 @@ namespace Tgstation.Server.Tests.Live.Instance // needs to just be valid connectionString = new DiscordConnectionStringBuilder { - BasedMeme = true, BotToken = "some_token", DeploymentBranding = true, DMOutputDisplay = DiscordDMOutputDisplayType.Always, diff --git a/tools/Tgstation.Server.Migrator.Comms/Program.cs b/tools/Tgstation.Server.Migrator.Comms/Program.cs index e83f874734..754d9e69d5 100644 --- a/tools/Tgstation.Server.Migrator.Comms/Program.cs +++ b/tools/Tgstation.Server.Migrator.Comms/Program.cs @@ -168,7 +168,6 @@ static class Program var discordSetupInfo = new DiscordSetupInfo(providerInfo); csb = new DiscordConnectionStringBuilder { - BasedMeme = false, DMOutputDisplay = DiscordDMOutputDisplayType.Always, BotToken = discordSetupInfo.BotToken };