Skip to content
This repository was archived by the owner on Oct 4, 2019. It is now read-only.

Commit 652074f

Browse files
committed
built-in help command will now capitalize first letter of title
1 parent 68994cd commit 652074f

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

commands/help.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Command.code = async (client, message) => {
1414
var {command} = client.dataStore.commands.get(message.content.split(" ")[1].toLowerCase())
1515
var data = await getData()
1616
if (message.channel.permissionsFor(message.guild.members.get(client.user.id)).serialize().EMBED_LINKS) {
17-
embed.setTitle(command.name + " command information")
17+
embed.setTitle(cap(command.name) + " command information")
1818
embed.addField("Name", command.name)
1919
embed.addField("Level required", command.level)
2020
embed.addField("Description", command.description)
@@ -111,7 +111,9 @@ Command.code = async (client, message) => {
111111
return levels.get(i.command.level) == false
112112
})
113113
}
114+
}
114115

115-
116+
function cap(string) {
117+
return string.charAt(0).toUpperCase() + string.toLowerCase().slice(1);
116118
}
117119
module.exports = Command;

0 commit comments

Comments
 (0)