diff --git a/README.md b/README.md index 0bd2073..00e6a32 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # WARNING: this is a pre-version The version above is unstable so if you find bugs, please report them in the discord server -[click here for a stable version](https://www.github.com/DJj123dj/open-ticket/releases/tab/v1.3.2) +[click here for a stable version](https://www.github.com/DJj123dj/open-ticket/releases/tab/v1.3.2a) # open-ticket diff --git a/commands/help.js b/commands/help.js index 9608613..38fd500 100644 --- a/commands/help.js +++ b/commands/help.js @@ -1,7 +1,7 @@ const discord = require('discord.js') const bot = require('../index') const client = bot.client -const config = require("../config.json") +const config = bot.config module.exports = () => { const helpEmbed = new discord.MessageEmbed() diff --git a/commands/ticket.js b/commands/ticket.js index fce17e7..f76af3c 100644 --- a/commands/ticket.js +++ b/commands/ticket.js @@ -1,7 +1,7 @@ const discord = require('discord.js') const bot = require('../index') const client = bot.client -const config = require("../config.json") +const config = bot.config /** ============================= ** NOT READY YET diff --git a/core/closebuttons.js b/core/closebuttons.js index 0cd6ea9..a771278 100644 --- a/core/closebuttons.js +++ b/core/closebuttons.js @@ -1,7 +1,7 @@ const discord = require('discord.js') const bot = require('../index') const client = bot.client -const config = require("../config.json") +const config = bot.config module.exports = () => { diff --git a/core/getoptions.js b/core/getoptions.js index 60ff236..a8a7744 100644 --- a/core/getoptions.js +++ b/core/getoptions.js @@ -1,4 +1,5 @@ -const config = require("../config.json") +const bot = require("../index") +const config = bot.config /** * @param {Number} index diff --git a/core/slashSystem/slashDisable.js b/core/slashSystem/slashDisable.js index 0eef12a..e89a254 100644 --- a/core/slashSystem/slashDisable.js +++ b/core/slashSystem/slashDisable.js @@ -1,6 +1,7 @@ const discord = require("discord.js") +const bot = require("../../index") const client = require("../../index").client -const config = require("../../config.json") +const config = bot.config const getoptions = require("../getoptions") module.exports = async () => { diff --git a/core/slashSystem/slashEnable.js b/core/slashSystem/slashEnable.js index fd0e448..e91d5c0 100644 --- a/core/slashSystem/slashEnable.js +++ b/core/slashSystem/slashEnable.js @@ -1,6 +1,7 @@ const discord = require("discord.js") +const bot = require("../../index") const client = require("../../index").client -const config = require("../../config.json") +const config = bot.config const getoptions = require("../getoptions") module.exports = async () => { diff --git a/core/ticketCloser.js b/core/ticketCloser.js index ffbd234..2e4c307 100644 --- a/core/ticketCloser.js +++ b/core/ticketCloser.js @@ -1,7 +1,7 @@ const discord = require('discord.js') const bot = require('../index') const client = bot.client -const config = require("../config.json") +const config = bot.config const ticketStorage = bot.TicketStorage const userTicketStorage = bot.userTicketStorage diff --git a/core/ticketMessageEmbed.js b/core/ticketMessageEmbed.js index 2d85bee..f681180 100644 --- a/core/ticketMessageEmbed.js +++ b/core/ticketMessageEmbed.js @@ -1,7 +1,7 @@ const discord = require('discord.js') const bot = require('../index') const client = bot.client -const config = require("../config.json") +const config = bot.config const getOptions = require("./getoptions") const getbyId = getOptions.getOptionsById diff --git a/core/ticketOpener.js b/core/ticketOpener.js index 81b3dfb..ea2d4d2 100644 --- a/core/ticketOpener.js +++ b/core/ticketOpener.js @@ -1,7 +1,7 @@ const discord = require('discord.js') const bot = require('../index') const client = bot.client -const config = require("../config.json") +const config = bot.config const getconfigoptions = require("./getoptions") diff --git a/core/transcript.js b/core/transcript.js index 475b33a..61a0dd0 100644 --- a/core/transcript.js +++ b/core/transcript.js @@ -1,7 +1,7 @@ const discord = require('discord.js') const bot = require('../index') const client = bot.client -const config = require("../config.json") +const config = bot.config /** * diff --git a/core/utils/getTicketMessages.js b/core/utils/getTicketMessages.js index 278afb7..22ed608 100644 --- a/core/utils/getTicketMessages.js +++ b/core/utils/getTicketMessages.js @@ -1,4 +1,5 @@ -const config = require("../../config.json") +const bot = require("../../index") +const config = bot.config exports.getTicketMessage = (input) => { var returned = config.messages.find(a => a.id == input) if (returned){ diff --git a/index.js b/index.js index ffa0265..c7bc453 100644 --- a/index.js +++ b/index.js @@ -9,7 +9,7 @@ client.setMaxListeners(20) const isDev = true //!!!!!!!!!!! -if (isDev){const config = require('./devConfig.json')}else{const config = require('./config.json')} +if (isDev){var config = require('./devConfig.json')}else{var config = require('./config.json')} exports.config = config client.on('ready',async () => { diff --git a/storage/userTickets/970615545403678750 b/storage/userTickets/970615545403678750 new file mode 100644 index 0000000..71d7104 --- /dev/null +++ b/storage/userTickets/970615545403678750 @@ -0,0 +1 @@ +779742674932072469 \ No newline at end of file