-
-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Settings Command Issue #841
Comments
Thanks for the bug report! Could you help to verify if the issue persists on stable? |
Oki let me check :D |
Same thing sadly
|
That's a little odd, stable is tested to be working. Could you show your settings.json? (blur out any sensitive information like tokens!) |
|
Leaving the As for the bug, i'll just post the relevant code involved as it's still unclear to me. export async function buildSettingsPage(
interaction: Interaction,
guildLocaleCode: keyof typeof Language,
option: SettingsPageOptions,
): Promise<SettingsPage> {
let current: string,
embeds: EmbedBuilder[] = [];
const actionRow = new ActionRowBuilder<MessageActionRowComponentBuilder>();
switch (option) {
case 'premium': {
current = '';
actionRow.addComponents(
new ButtonBuilder()
.setLabel(
await getGuildLocaleString(
interaction.guildId,
'MISC.GET_PREMIUM',
),
)
.setStyle(ButtonStyle.Link)
.setURL(settings.premiumURL),
);
const whitelisted = {
stay: await data.guild.get<number>(
interaction.guildId,
'features.stay.whitelisted',
),
autolyrics: await data.guild.get<number>(
interaction.guildId,
'features.autolyrics.whitelisted',
),
smartqueue: await data.guild.get<number>(
interaction.guildId,
'features.smartqueue.whitelisted',
),
};
const features = Object.keys(whitelisted)
.filter(
(key: WhitelistedFeatures): boolean =>
settings.features[key].enabled &&
settings.features[key].whitelist &&
settings.features[key].premium,
)
.map(
(key: WhitelistedFeatures): string =>
`**${getLocaleString(
guildLocaleCode,
`CMD.SETTINGS.MISC.PREMIUM.FEATURES.${key.toUpperCase()}`,
)}** ─ ${
!whitelisted[key]
? getLocaleString(
guildLocaleCode,
'CMD.SETTINGS.MISC.PREMIUM.DISPLAY.LOCKED.DEFAULT',
)
: whitelisted[key] !== -1 &&
Date.now() > whitelisted[key]
? getLocaleString(
guildLocaleCode,
'CMD.SETTINGS.MISC.PREMIUM.DISPLAY.LOCKED.EXPIRED',
Math.floor(
whitelisted[key] / 1000,
).toString(),
)
: whitelisted[key] === -1
? getLocaleString(
guildLocaleCode,
'CMD.SETTINGS.MISC.PREMIUM.DISPLAY.UNLOCKED.PERMANENT',
)
: getLocaleString(
guildLocaleCode,
'CMD.SETTINGS.MISC.PREMIUM.DISPLAY.UNLOCKED.TEMPORARY',
Math.floor(
whitelisted[key] / 1000,
).toString(),
)
}`,
);
// features = []
embeds = [
new EmbedBuilder()
.setDescription(features.join('\n'))
.setColor(settings.colors.neutral),
];
break;
}
export const settingsOptions = [
...(settings.premiumURL ? ['premium'] : []), // <--
'language',
'format',
'dj',
'autolyrics',
'smartqueue',
]; |
Thanks alot!! |
@LifeDreamer24 I'd like to mention that
As for the issue, I'll take a closer look. |
Hi @LifeDreamer24, I've confirmed that the bug is related to the managers field. Try doing the step that I showed above and let me know if the bug still occurs. You can get your user ID here: https://support.discord.com/hc/en-us/articles/206346498-Where-can-I-find-my-User-Server-Message-ID- |
Describe the bug
The settings command is not working on my side...
Severity
Medium
Affected branches
Quaver version
6.10.0-next.1
Steps to reproduce
Expected behavior
Settings command should be working but does not. (For me)
Actual behavior
Says that the application didn't respond and it prints an error in the console.
Relevant log output
The text was updated successfully, but these errors were encountered: