aboutsummaryrefslogtreecommitdiff
path: root/handler
diff options
context:
space:
mode:
authorMinteck <contact@minteck.org>2022-02-11 18:46:01 +0100
committerMinteck <contact@minteck.org>2022-02-11 18:46:01 +0100
commit395c72df876e2674b562ff95f8f867b6f6d3cba8 (patch)
tree7923cfc4c15e86f2e59058369b763a5b21c2433f /handler
parenta7102acd6fda9168b057d90c961618aead034336 (diff)
downloadponyfind-395c72df876e2674b562ff95f8f867b6f6d3cba8.tar.gz
ponyfind-395c72df876e2674b562ff95f8f867b6f6d3cba8.tar.bz2
ponyfind-395c72df876e2674b562ff95f8f867b6f6d3cba8.zip
Feature: implements #6
Diffstat (limited to 'handler')
-rw-r--r--handler/button.js6
1 files changed, 2 insertions, 4 deletions
diff --git a/handler/button.js b/handler/button.js
index c5cfb19..3fbebbe 100644
--- a/handler/button.js
+++ b/handler/button.js
@@ -4,6 +4,7 @@ const { MessageActionRow, MessageButton, MessageSelectMenu, MessageEmbed, Messag
const getPixel = require('../modules/pixel.js');
const getEmbed = require("../modules/embed");
+const getPublic = require("../modules/public");
module.exports = async (interaction) => {
keys = interaction.customId.split("|")
@@ -26,10 +27,7 @@ module.exports = async (interaction) => {
if (interaction.guild) {
row = new MessageActionRow()
.addComponents(
- new MessageButton()
- .setCustomId("pony.public|" + keys[1])
- .setLabel(l("Show to everypony", "Afficher à tous", interaction.user.id, interaction.guild ? interaction.guild.id : 0))
- .setStyle("PRIMARY"),
+ getPublic(interaction, keys),
new MessageButton()
.setLabel(l("Read More", "Lire plus", interaction.user.id, interaction.guild ? interaction.guild.id : 0))
.setStyle("LINK")