diff --git a/src/utils/archive.js b/src/utils/archive.js index 8fa4d97..f16bdab 100644 --- a/src/utils/archive.js +++ b/src/utils/archive.js @@ -3,7 +3,7 @@ export const allowedCategories = ['🪂 SORTIES', '🏃Sorties pas rapente', ' export async function archive(channel) { const archiveCategories = channel.guild.channels.cache.filter(channel => channel.type === 4 && channel.name.slice(0,11).toLowerCase() === '📁archives_'); - let available_archive = archiveCategories.find(cat => cat.children.cache.size < 3) + let available_archive = archiveCategories.find(cat => cat.children.cache.size < 50) if (available_archive) { channel.setParent(available_archive) @@ -11,7 +11,7 @@ export async function archive(channel) { // creating a new archive category const count = Math.max(...archiveCategories.map(cat => parseInt(cat.name.split('_')[1]))) available_archive = await channel.guild.channels.create({ - name: `📁archives_${count + 1}`, + name: `📁ARCHIVES_${count + 1}`, type: 4, }) console.log('Created new archive category');