Skip to content

Commit

Permalink
Fix gender should be voiceGender
Browse files Browse the repository at this point in the history
  • Loading branch information
alexemanuelol committed Sep 3, 2023
1 parent 08b06fd commit 365c74c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/discordTools/discordVoice.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ module.exports = {

getVoice: async function (guildId) {
const instance = Client.client.getInstance(guildId);
const gender = instance.generalSettings.gender;
const gender = instance.generalSettings.voiceGender;
const language = instance.generalSettings.language;

if (Actors[language]?.[gender] === null || Actors[language]?.[gender] === undefined) {
Expand Down
6 changes: 3 additions & 3 deletions src/handlers/selectMenuHandler.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,14 +113,14 @@ module.exports = async (client, interaction) => {
});
}
else if (interaction.customId === 'VoiceGender') {
instance.generalSettings.gender = interaction.values[0];
instance.generalSettings.voiceGender = interaction.values[0];
client.setInstance(guildId, instance);

if (rustplus) rustplus.generalSettings.gender = interaction.values[0];
if (rustplus) rustplus.generalSettings.voiceGender = interaction.values[0];

client.log(client.intlGet(null, 'infoCap'), client.intlGet(null, 'selectMenuValueChange', {
id: `${verifyId}`,
value: `${instance.generalSettings.gender}`
value: `${instance.generalSettings.voiceGender}`
}));

await client.interactionUpdate(interaction, {
Expand Down

0 comments on commit 365c74c

Please sign in to comment.