changed Bot to App
This commit is contained in:
@@ -7,6 +7,9 @@ import (
|
|||||||
func setAutoJoinRole(guildID string, option string, roleID string) bool {
|
func setAutoJoinRole(guildID string, option string, roleID string) bool {
|
||||||
var role_exists bool
|
var role_exists bool
|
||||||
var autojoinroles_exists bool
|
var autojoinroles_exists bool
|
||||||
|
if option == "app" { // stop renaming stuff Discord
|
||||||
|
option = "bot"
|
||||||
|
}
|
||||||
err := db.QueryRow("SELECT EXISTS (SELECT 1 FROM autojoinroles WHERE guild_id = $1)", guildID).Scan(&autojoinroles_exists)
|
err := db.QueryRow("SELECT EXISTS (SELECT 1 FROM autojoinroles WHERE guild_id = $1)", guildID).Scan(&autojoinroles_exists)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logrus.Error(err)
|
logrus.Error(err)
|
||||||
|
@@ -47,12 +47,12 @@ var Plugin = &shared.Plugin{
|
|||||||
discord.ApplicationIntegrationTypeGuildInstall},
|
discord.ApplicationIntegrationTypeGuildInstall},
|
||||||
Options: []discord.ApplicationCommandOption{
|
Options: []discord.ApplicationCommandOption{
|
||||||
&discord.ApplicationCommandOptionSubCommand{
|
&discord.ApplicationCommandOptionSubCommand{
|
||||||
Name: "bot",
|
Name: "app",
|
||||||
Description: "Give bots a role when they join (Leave empty to remove current)",
|
Description: "Give apps a role when they join (Leave empty to remove current)",
|
||||||
Options: []discord.ApplicationCommandOption{
|
Options: []discord.ApplicationCommandOption{
|
||||||
&discord.ApplicationCommandOptionRole{
|
&discord.ApplicationCommandOptionRole{
|
||||||
Name: "role",
|
Name: "role",
|
||||||
Description: "The role bots should get when they join the server",
|
Description: "The role apps should get when they join the server",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@@ -12,7 +12,7 @@ var Plugin = &shared.Plugin{
|
|||||||
{
|
{
|
||||||
Definition: discord.SlashCommandCreate{
|
Definition: discord.SlashCommandCreate{
|
||||||
Name: "info",
|
Name: "info",
|
||||||
Description: "Gives you information about a user or this bot.",
|
Description: "Gives you information about a user or this app.",
|
||||||
Contexts: []discord.InteractionContextType{
|
Contexts: []discord.InteractionContextType{
|
||||||
discord.InteractionContextTypeGuild,
|
discord.InteractionContextTypeGuild,
|
||||||
discord.InteractionContextTypePrivateChannel,
|
discord.InteractionContextTypePrivateChannel,
|
||||||
@@ -35,8 +35,8 @@ var Plugin = &shared.Plugin{
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
&discord.ApplicationCommandOptionSubCommand{
|
&discord.ApplicationCommandOptionSubCommand{
|
||||||
Name: "bot-service",
|
Name: "app-service",
|
||||||
Description: "Gives you information about this bot's server service.",
|
Description: "Gives you information about this app's server service.",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
@@ -44,7 +44,7 @@ var Plugin = &shared.Plugin{
|
|||||||
switch *e.SlashCommandInteractionData().SubCommandName {
|
switch *e.SlashCommandInteractionData().SubCommandName {
|
||||||
case "user":
|
case "user":
|
||||||
user(e)
|
user(e)
|
||||||
case "bot-service":
|
case "app-service":
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -45,7 +45,7 @@ var Plugin = &shared.Plugin{
|
|||||||
Options: []discord.ApplicationCommandOption{
|
Options: []discord.ApplicationCommandOption{
|
||||||
discord.ApplicationCommandOptionSubCommand{
|
discord.ApplicationCommandOptionSubCommand{
|
||||||
Name: "get",
|
Name: "get",
|
||||||
Description: "A command to get messages saved to the bot.",
|
Description: "A command to get messages saved to this app.",
|
||||||
Options: []discord.ApplicationCommandOption{
|
Options: []discord.ApplicationCommandOption{
|
||||||
discord.ApplicationCommandOptionString{
|
discord.ApplicationCommandOptionString{
|
||||||
Name: "tag",
|
Name: "tag",
|
||||||
@@ -57,11 +57,11 @@ var Plugin = &shared.Plugin{
|
|||||||
},
|
},
|
||||||
discord.ApplicationCommandOptionSubCommand{
|
discord.ApplicationCommandOptionSubCommand{
|
||||||
Name: "add",
|
Name: "add",
|
||||||
Description: "A command to add messages saved to the bot.",
|
Description: "A command to add messages saved to this app.",
|
||||||
},
|
},
|
||||||
discord.ApplicationCommandOptionSubCommand{
|
discord.ApplicationCommandOptionSubCommand{
|
||||||
Name: "remove",
|
Name: "remove",
|
||||||
Description: "A command to remove messages saved to the bot.",
|
Description: "A command to remove messages saved to this app.",
|
||||||
Options: []discord.ApplicationCommandOption{
|
Options: []discord.ApplicationCommandOption{
|
||||||
discord.ApplicationCommandOptionString{
|
discord.ApplicationCommandOptionString{
|
||||||
Name: "tag",
|
Name: "tag",
|
||||||
|
@@ -108,7 +108,7 @@
|
|||||||
acecore at any time by removing it from your Discord server. Please do
|
acecore at any time by removing it from your Discord server. Please do
|
||||||
note that if you still share any server with acecore, limited public
|
note that if you still share any server with acecore, limited public
|
||||||
data provided by Discord might still be collected when other people use
|
data provided by Discord might still be collected when other people use
|
||||||
the bot.
|
the Discord app.
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
<h2 id="data-retention">Data Retention:</h2>
|
<h2 id="data-retention">Data Retention:</h2>
|
||||||
|
Reference in New Issue
Block a user