Skip to content

Commit

Permalink
fix calling sprintf
Browse files Browse the repository at this point in the history
  • Loading branch information
ikafly144 committed Oct 9, 2024
1 parent def533c commit 4e7e223
Showing 1 changed file with 5 additions and 10 deletions.
15 changes: 5 additions & 10 deletions bot/commands/permission/permission.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
package permission

import (
"fmt"

"github.com/disgoorg/disgo/discord"
"github.com/disgoorg/disgo/events"
"github.com/disgoorg/snowflake/v2"
Expand All @@ -19,9 +17,8 @@ func Command(c *components.Components) components.Command {
Namespace: "permission",
CommandCreate: []discord.ApplicationCommandCreate{
discord.SlashCommandCreate{
Name: "permission",
Description: "permission",
DMPermission: builtin.Ptr(false),
Name: "permission",
Description: "permission",
Contexts: []discord.InteractionContextType{
discord.InteractionContextTypeGuild,
},
Expand Down Expand Up @@ -284,11 +281,9 @@ func Command(c *components.Components) components.Command {
embeds.SetEmbedProperties(
discord.NewEmbedBuilder().
SetTitle(translate.Message(event.Locale(), "components.permission.list.message.embed.title")).
SetDescriptionf(
fmt.Sprintf("%s```yaml\n%s```",
mention,
builtin.Or(str != "", str, "Empty"),
),
SetDescriptionf("%s```yaml\n%s```",
mention,
builtin.Or(str != "", str, "Empty"),
).
Build(),
),
Expand Down

0 comments on commit 4e7e223

Please sign in to comment.