Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
b5fb409
deprecated old interaction fn
bng94 Jul 22, 2025
a1a6fc3
Merge branch 'dev' of https://github.com/bng94/discord-features-handl…
bng94 Aug 9, 2025
1b1642e
Merge branch 'master' into dev
bng94 Aug 9, 2025
1662439
updated .yml to work on pull request
bng94 Aug 9, 2025
d284127
add executePrefix property to cmds and recommend conversion
bng94 Aug 16, 2025
e36d53e
add executePrefix property to cmds and recommend conversion
bng94 Aug 16, 2025
532b3e0
Update dfhMessageCreate.js
bng94 Aug 16, 2025
09ed13d
updated doc for v3.1.0
bng94 Aug 16, 2025
2372da3
Merge branch 'master' into dev
bng94 Aug 16, 2025
b309249
update release note for v3.1.0
bng94 Aug 16, 2025
22dc4c8
Merge branch 'master' into dev
bng94 Aug 16, 2025
ef8fa11
3.1.0
bng94 Aug 16, 2025
f373864
doc changes for v3.1.0
bng94 Aug 17, 2025
e03071b
Merge branch 'master' into dev
bng94 Aug 17, 2025
6650151
Update help-command.md
bng94 Aug 17, 2025
09671de
updated to latest discordjs
bng94 Aug 17, 2025
39ac823
Make selective Command Properties optional in v3.1
bng94 Aug 17, 2025
7538cdd
Make selective Command Properties optional in v3.1
bng94 Aug 17, 2025
4848c63
Merge branch 'dev' of https://github.com/bng94/discord-features-handl…
bng94 Aug 17, 2025
8b8353e
Update dfhInteractionCreate.js
bng94 Aug 17, 2025
67a1278
Update README.md
bng94 Aug 17, 2025
85c52f2
updated dfhHelp cmd with customIdInteraction fn
bng94 Aug 17, 2025
a063d7c
add try/catch to the dfhhelp customidinteraction fn
bng94 Aug 18, 2025
8660082
change customIds to array<string> and add global property
bng94 Aug 18, 2025
3c06129
updated slashCommandIdsToDelete to be object property
bng94 Aug 18, 2025
553aa85
Update publish-release.yml
bng94 Aug 18, 2025
7655b55
Update publish-release.yml
bng94 Aug 18, 2025
ed64adb
Merge branch 'master' into dev
bng94 Aug 18, 2025
ca2ad36
Merge branch 'master' into dev
bng94 Aug 18, 2025
25f49ae
Fix issue where showing console warning when slashCommandIdsToDelete …
bng94 Aug 18, 2025
559cf02
3.1.1
bng94 Aug 18, 2025
ee3b79e
Update release-notes.md
bng94 Aug 18, 2025
fa0ef23
Update publish-release.yml
bng94 Aug 18, 2025
0dfcb30
Merge branch 'master' into dev
bng94 Aug 18, 2025
5828128
Merge branch 'master' into dev
bng94 Aug 18, 2025
28884c3
combined one .yml file
bng94 Aug 18, 2025
35bb038
fixed typo in help cmd
bng94 Aug 18, 2025
b3dac59
Update loadCommands.js
bng94 Aug 19, 2025
c669ca4
3.1.2
bng94 Aug 19, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 0 additions & 29 deletions .github/workflows/deploy-docs.yml

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Create and Publish Release
name: Release and Deploy
on:
push:
branches:
Expand Down Expand Up @@ -45,13 +45,13 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "lts/*"
- name: Configure npm authentication
run: |
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_AUTH_TOKEN_AUTOMATION }}" > ~/.npmrc
node-version: "20"
registry-url: https://registry.npmjs.org
- name: Publish package
run: npm ci && npm publish
deploy:
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
deploy-docs:
runs-on: ubuntu-latest
needs: publish-package
steps:
Expand Down
24 changes: 9 additions & 15 deletions docs/builtIn/help-command.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,6 @@ module.exports = {
return message.reply(response).catch((error) => console.log(error));
}
},
/**
* Missing data property if you plan to turn this into a slash command!
*/
async execute(interaction, client, level) {
await interaction.deferReply({
ephemeral: true,
Expand Down Expand Up @@ -118,9 +115,7 @@ module.exports = {
content: "An error occurred while processing your request.",
ephemeral: true,
})
.catch((e) => {

});
.catch(() => {});
}
},
};
Expand Down Expand Up @@ -311,21 +306,21 @@ const getSingleCmd = async (commands, name, client) => {
const fieldObj = [];
fieldObj.push({
name: `Category:`,
value: `${command.category}`,
value: `${slashCommand.category}`,
inline: true,
});

fieldObj.push({
name: `Usage:`,
value: `/${command.name}`,
value: `/${slashCommand.name}`,
inline: true,
});
if (command.executePrefix) {
if (slashCommand.executePrefix) {
fieldObj.push({
name: `Using prefix:`,
value: `${prefix}${command.name} ${command.usage}${
command.aliases
? `, ${prefix}${command.aliases.join(`, ${prefix}`)}`
value: `${prefix}${slashCommand.name} ${slashCommand.usage}${
slashCommand.aliases
? `, ${prefix}${slashCommand.aliases.join(`, ${prefix}`)}`
: ""
}`,
});
Expand All @@ -336,8 +331,8 @@ const getSingleCmd = async (commands, name, client) => {
name: `${client.user.tag}`,
iconURL: `${client.user.avatarURL()}`,
})
.setTitle(`${command.data.name.toProperCase()} Command`)
.setDescription(command.data.description)
.setTitle(`${slashCommand.data.name.toProperCase()} Command`)
.setDescription(slashCommand.data.description)
.setTimestamp()
.setFields(fieldObj);

Expand Down Expand Up @@ -394,5 +389,4 @@ const getSingleCmd = async (commands, name, client) => {
};
}
};

```
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "discord-features-handler",
"version": "3.1.1",
"version": "3.1.2",
"description": "An simple discord regular and slash commands, events and modules handler with folder structure",
"main": "src/index.js",
"types": "src/index.d.ts",
Expand Down
16 changes: 8 additions & 8 deletions src/commands/miscellaneous/dfhHelp.js
Original file line number Diff line number Diff line change
Expand Up @@ -296,21 +296,21 @@ const getSingleCmd = async (commands, name, client) => {
const fieldObj = [];
fieldObj.push({
name: `Category:`,
value: `${command.category}`,
value: `${slashCommand.category}`,
inline: true,
});

fieldObj.push({
name: `Usage:`,
value: `/${command.name}`,
value: `/${slashCommand.name}`,
inline: true,
});
if (command.executePrefix) {
if (slashCommand.executePrefix) {
fieldObj.push({
name: `Using prefix:`,
value: `${prefix}${command.name} ${command.usage}${
command.aliases
? `, ${prefix}${command.aliases.join(`, ${prefix}`)}`
value: `${prefix}${slashCommand.name} ${slashCommand.usage}${
slashCommand.aliases
? `, ${prefix}${slashCommand.aliases.join(`, ${prefix}`)}`
: ""
}`,
});
Expand All @@ -321,8 +321,8 @@ const getSingleCmd = async (commands, name, client) => {
name: `${client.user.tag}`,
iconURL: `${client.user.avatarURL()}`,
})
.setTitle(`${command.data.name.toProperCase()} Command`)
.setDescription(command.data.description)
.setTitle(`${slashCommand.data.name.toProperCase()} Command`)
.setDescription(slashCommand.data.description)
.setTimestamp()
.setFields(fieldObj);

Expand Down
3 changes: 1 addition & 2 deletions src/handlers/loadCommands.js
Original file line number Diff line number Diff line change
Expand Up @@ -140,10 +140,9 @@ module.exports = ({

client.commands.forEach((cmd) => {
if ("data" in cmd && ("interactionReply" in cmd || "execute" in cmd)) {
slashCommands.push(cmd.data.toJSON());
if ("global" in cmd && cmd.global === true) {
globalSlashCommands.push(cmd.data.toJSON());
} else {
slashCommands.push(cmd.data.toJSON());
}
}
});
Expand Down