~denisebitca/esmeralde

8e566bd7c98d5f8eb4e83b76df20e5e8d71747ac — Rafael Bitca 2 years ago 05a1df6
Still trying to fix this.........
2 files changed, 2 insertions(+), 3 deletions(-)

M src/FollowupFunctions.ts
M src/index.ts
M src/FollowupFunctions.ts => src/FollowupFunctions.ts +2 -2
@@ 64,8 64,8 @@ export class FollowupFunctions{
            "userList": config.userList.length === 0 ? [newUser] : config.userList.concat([newUser])
        }
        console.log(path.join(__dirname, "config.json"));
        await fs.promises.writeFile("./config.json", JSON.stringify(configCopy, null, 2), {encoding: "utf-8"});
        await fs.promises.rm(path.join(__dirname, interaction.user.id + ".json"));
        fs.writeFileSync("./config.json", JSON.stringify(configCopy, null, 2), {encoding: "utf-8"});
        fs.rmSync(path.join(__dirname, interaction.user.id + ".json"));
        await interaction.update({content: "Ton emploi du temps a été enregistré !", embeds: [], components: []});
    }


M src/index.ts => src/index.ts +0 -1
@@ 71,7 71,6 @@ client.on('interactionCreate', async interaction => {
			FollowupFunctions.followUpActionMenu1_edt(interaction);
		} else if (interaction.customId === 'select3') {
			FollowupFunctions.followUpActionMenu2_edt(interaction);
			config = JSON.parse(fs.readFileSync(path.join(__dirname, "config.json"), {encoding: "utf-8"}));
		}
    } else if(interaction.isCommand()){
        const command = client.commands.get(interaction.commandName);