removed any mention of Alter from the user-facing code
This commit is contained in:
parent
209bdeb1b3
commit
8a6f2f6562
7 changed files with 18 additions and 18 deletions
|
@ -18,7 +18,7 @@ export async function avatarAlterChange(userId: string, args: string[]){
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
return "The profile picture has been changed"
|
return "The profile picture for the Member has been changed"
|
||||||
}
|
}
|
||||||
|
|
||||||
if (args.length != 2) {
|
if (args.length != 2) {
|
||||||
|
|
|
@ -11,7 +11,7 @@ export async function colorAlterChange(userId: string, args: string[]){
|
||||||
|
|
||||||
let alters: AlterModel[];
|
let alters: AlterModel[];
|
||||||
await alterRepo.getAltersByUserId(userId).then( result => alters = result ) // fetching alters from user.
|
await alterRepo.getAltersByUserId(userId).then( result => alters = result ) // fetching alters from user.
|
||||||
if (alters.length == 0) return "This user has no Alters." // checking if returned array is at least not 0, if len 0, then return.
|
if (alters.length == 0) return "This user has no Members." // checking if returned array is at least not 0, if len 0, then return.
|
||||||
|
|
||||||
let alterToEdit: AlterModel;
|
let alterToEdit: AlterModel;
|
||||||
alters.forEach( alter => {
|
alters.forEach( alter => {
|
||||||
|
@ -23,7 +23,7 @@ export async function colorAlterChange(userId: string, args: string[]){
|
||||||
alterToEdit.color = alterColor;
|
alterToEdit.color = alterColor;
|
||||||
alterRepo.editAlter(alterToEdit)
|
alterRepo.editAlter(alterToEdit)
|
||||||
|
|
||||||
return "The Alter's colour has been changed."
|
return "The Member's colour has been changed."
|
||||||
}
|
}
|
||||||
|
|
||||||
return "Error: Insufficent Arguments"
|
return "Error: Insufficent Arguments"
|
||||||
|
|
|
@ -31,7 +31,7 @@ export async function createAlter(userId: string, args: string[]){
|
||||||
&& !alterNames.includes(args[0])) {
|
&& !alterNames.includes(args[0])) {
|
||||||
|
|
||||||
alterRepo.addAlterForUser(model);
|
alterRepo.addAlterForUser(model);
|
||||||
return {message: "Alter < " + model.name + " > has been succefully created", code: 0}
|
return {message: "Member < " + model.name + " > has been succefully created", code: 0}
|
||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -45,10 +45,10 @@ export async function createAlter(userId: string, args: string[]){
|
||||||
return {message: "Error: This command requires a tag that contains <text> in it", code: 3};
|
return {message: "Error: This command requires a tag that contains <text> in it", code: 3};
|
||||||
}
|
}
|
||||||
if (alterTags.includes(args[1])) {
|
if (alterTags.includes(args[1])) {
|
||||||
return {message: "Error: You already have an Alter with that tag", code: 4}
|
return {message: "Error: You already have a Member with that tag", code: 4}
|
||||||
}
|
}
|
||||||
if (alterNames.includes(args[0])) {
|
if (alterNames.includes(args[0])) {
|
||||||
return {message: "Error: You can only have one Alter with that name", code: 5}
|
return {message: "Error: You can only have one Member with that name", code: 5}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,9 +16,9 @@ export async function deleteAlter(userId: string, args: string[]) {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
if (success) {
|
if (success) {
|
||||||
return "Alter has been deleted"
|
return "Member has been deleted"
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
return "Failed to delete Alter"
|
return "Failed to delete Member"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,15 +1,15 @@
|
||||||
export function returnHelpText() {
|
export function returnHelpText() {
|
||||||
return "# Howdy user, welcome to pluralcake\n" +
|
return "# Howdy user, welcome to pluralcake\n" +
|
||||||
"pluralcake is a bot that allows you to send messages as your Alters, with a custom profile picture, tag and nickname. \n" +
|
"pluralcake is a bot that allows you to send messages as your system's Members, with a custom profile picture, tag and nickname. \n" +
|
||||||
"It's pretty much a work in progress, and doesn't allow you to edit or delete messages, and to send pictures." +
|
"It's pretty much a work in progress, and doesn't allow you to edit or delete messages, and to send pictures." +
|
||||||
"The currently available commands are : \n" +
|
"The currently available commands are : \n" +
|
||||||
"### Alters:\n" +
|
"### Alters:\n" +
|
||||||
"- list | allows you to see your currently available alters.\n" +
|
"- list | allows you to see your currently available Members.\n" +
|
||||||
"- create <'name of the alter'> <'your alter s tag'>| Allows you to create your Alters\n" +
|
"- create <'name of the Member'> <'your Member's tag'>| Allows you to add a Member\n" +
|
||||||
"- delete <'name of the alter'> | Deletes the choosen Alter\n" +
|
"- delete <'name of the Member'> | Deletes the choosen Member\n" +
|
||||||
"- name <'name of the alter'> | Changes the choosen Alter's name\n" +
|
"- name <'name of the Member'> | Changes the choosen Member's name\n" +
|
||||||
"- avatar <'Alter's name'> <'picture url'> | Allows you to edit your alter's profile picture\n" +
|
"- avatar <'Member's name'> <'picture url'> | Allows you to edit your Member's profile picture\n" +
|
||||||
"- color <'Alter's name'> <'color hex'> | Allows you to change the color of your alter ( may be integrated with the future website )\n"+
|
"- color <'Member's name'> <'color hex'> | Allows you to change the color of your Member ( may be integrated with the future website )\n"+
|
||||||
"### Migrations\n"+
|
"### Migrations\n"+
|
||||||
"- tupper < Json file attached > | Migrates your alters from tupper to pluralcake"
|
"- tupper < Json file attached > | Migrates your Member from tupper"
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,6 +11,6 @@ export async function listAlters(userId: string) {
|
||||||
return tableConstructor(alters)
|
return tableConstructor(alters)
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
return "No Alters found for this user"
|
return "No Members found for this user"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,7 +32,7 @@ export default async function migrateAlters(author: string, attachments: File[]
|
||||||
|
|
||||||
console.log(tupperStruct)
|
console.log(tupperStruct)
|
||||||
});
|
});
|
||||||
return "Migration finished, check your tuppers to confirm"
|
return "Migration finished, check your Members to confirm"
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
return "This is not a valid json file"
|
return "This is not a valid json file"
|
||||||
|
|
Loading…
Reference in a new issue