mirror of
https://github.com/koreanbots/core.git
synced 2025-12-15 14:10:22 +00:00
deps: change discord.js version to v14 (#503)
* deps: update djs to v14 * refactor: use discord.js v14 * fix: presence not showing properly * fix: revert Ids * Update pages/api/v2/bots/[id]/index.ts Co-authored-by: Junseo Park <wonderlandpark@outlook.kr> * style: apply code style * feat: customizable intents * feat: change node version * feat: change node version * fix: misused operator * deps: fix typescript version to 4.6.4 * fix: fix bot url length (#504) * refactor: add more advertisements (#508) * feat: add open review deny log and max denies restriction (#510) * feat: add open review log channel and embed * chore: do not include submit page * chore: mention instead of date * feat: add max denies error * typo: 더 이상 Co-authored-by: Junseo Park <wonderlandpark@outlook.kr> * feat: add exceptions to deny count * fix: invalid embed used Co-authored-by: Junseo Park <wonderlandpark@outlook.kr> * fix: invalid guild Co-authored-by: Junseo Park <wonderlandpark@outlook.kr> * fix: invalid position Co-authored-by: Junseo Park <wonderlandpark@outlook.kr> * fix: proper reason check position Co-authored-by: Junseo Park <wonderlandpark@outlook.kr> * feat: sepcific error message * refactor: change reason embed format * fix: knex andWhereNot method to whereNotIn method Co-authored-by: Junseo Park <wonderlandpark@outlook.kr> * refactor: detact adblock (#509) * refactor: detact adblock * perf: implement mobile detection * deps: update djs to v14 * refactor: use discord.js v14 * fix: presence not showing properly * fix: revert Ids * Update pages/api/v2/bots/[id]/index.ts Co-authored-by: Junseo Park <wonderlandpark@outlook.kr> * style: apply code style * feat: customizable intents * feat: change node version * feat: change node version * fix: misused operator * deps: fix typescript version to 4.6.4 * refactor: use discord.js v14 * deps: update discord.js to 14.2.0 * style: split options * style: prettify * deps: update erlpack Co-authored-by: Junseo Park <wonderlandpark@outlook.kr> Co-authored-by: Byungchul Kim <64084503+chul0721@users.noreply.github.com> Co-authored-by: Eunwoo Choi <61371424+eunwoo1104@users.noreply.github.com>
This commit is contained in:
parent
85385e94aa
commit
8694e9b19a
@ -13,6 +13,7 @@ DISCORD_CLIENT_ID=CLIENT_ID
|
||||
DISCORD_CLIENT_SECRET=CLIENT_SECRET
|
||||
DISCORD_SCOPE=SCOPE
|
||||
DISCORD_TOKEN=BOT_TOKEN
|
||||
DISCORD_CLIENT_INTENTS=32767
|
||||
|
||||
GITHUB_CLIENT_ID=GH_CLIENT_ID
|
||||
GITHUB_CLIENT_SECRET=GH_CLIENT_SECRET
|
||||
|
||||
12
.github/workflows/testing.yml
vendored
12
.github/workflows/testing.yml
vendored
@ -13,10 +13,10 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: install node v14
|
||||
- name: install node v16
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: 14
|
||||
node-version: 16
|
||||
- name: yarn install
|
||||
run: yarn install
|
||||
- name: run eslint
|
||||
@ -28,10 +28,10 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: install node v14
|
||||
- name: install node v16
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: 14
|
||||
node-version: 16
|
||||
- name: yarn install
|
||||
run: yarn install
|
||||
- name: Run Jest
|
||||
@ -41,10 +41,10 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: install node v14
|
||||
- name: install node v16
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: 14
|
||||
node-version: 16
|
||||
- name: yarn install
|
||||
run: yarn install
|
||||
- name: Build
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
FROM node:14.17-alpine
|
||||
FROM node:16.16-alpine
|
||||
|
||||
# install packages
|
||||
RUN apk update && apk upgrade && \
|
||||
|
||||
@ -29,9 +29,9 @@
|
||||
"dayjs": "^1.10.6",
|
||||
"dd-trace": "^1.1.0",
|
||||
"difflib": "0.2.4",
|
||||
"discord.js": "12.5.3",
|
||||
"discord.js": "^14.2.0",
|
||||
"emoji-mart": "3.0.1",
|
||||
"erlpack": "0.1.3",
|
||||
"erlpack": "0.1.4",
|
||||
"express-rate-limit": "^5.3.0",
|
||||
"formik": "2.2.9",
|
||||
"generate-license-file": "1.1.0",
|
||||
@ -100,7 +100,7 @@
|
||||
"prettier": "^2.3.2",
|
||||
"prettier-plugin-tailwind": "^2.2.12",
|
||||
"ts-jest": "27.0.4",
|
||||
"typescript": "^4.3.5"
|
||||
"typescript": "4.6.4"
|
||||
},
|
||||
"license": "AGPL-3.0"
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { NextApiRequest} from 'next'
|
||||
import rateLimit from 'express-rate-limit'
|
||||
import { MessageEmbed } from 'discord.js'
|
||||
import { EmbedBuilder } from 'discord.js'
|
||||
|
||||
import { get, update } from '@utils/Query'
|
||||
import RequestHandler from '@utils/RequestHandler'
|
||||
@ -42,7 +42,10 @@ const BotStats = RequestHandler()
|
||||
const d = await update.updateServer(botInfo.id, validated.servers, undefined)
|
||||
if(d===1 || d===2) return ResponseWrapper(res, { code: 403, message: `서버 수를 ${[null, '1만', '100만'][d]} 이상으로 설정하실 수 없습니다. 문의해주세요.`, version: 1 })
|
||||
get.bot.clear(bot)
|
||||
await getStatsLoggingChannel().send(`[BOT/STATS] <@${botInfo.id}> (${botInfo.id})\n${makeDiscordCodeblock(`${botInfo.servers > validated.servers ? '-' : '+'} ${botInfo.servers} -> ${validated.servers} (${botInfo.servers > validated.servers ? '▼' : '▲'}${Math.abs(validated.servers - botInfo.servers)})`, 'diff')}`, (new MessageEmbed().setDescription(`${botInfo.name} - <@${botInfo.id}> ([${botInfo.id}](${KoreanbotsEndPoints.URL.bot(botInfo.id)}))`)))
|
||||
await getStatsLoggingChannel().send({
|
||||
content: `[BOT/STATS] <@${botInfo.id}> (${botInfo.id})\n${makeDiscordCodeblock(`${botInfo.servers > validated.servers ? '-' : '+'} ${botInfo.servers} -> ${validated.servers} (${botInfo.servers > validated.servers ? '▼' : '▲'}${Math.abs(validated.servers - botInfo.servers)})`, 'diff')}`,
|
||||
embeds: [new EmbedBuilder().setDescription(`${botInfo.name} - <@${botInfo.id}> ([${botInfo.id}](${KoreanbotsEndPoints.URL.bot(botInfo.id)}`)]
|
||||
})
|
||||
return ResponseWrapper(res, { code: 200, message: '성공적으로 업데이트 했습니다.', version: 1 })
|
||||
})
|
||||
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { NextApiRequest } from 'next'
|
||||
import rateLimit from 'express-rate-limit'
|
||||
import { MessageEmbed } from 'discord.js'
|
||||
import { Colors, EmbedBuilder } from 'discord.js'
|
||||
import tracer from 'dd-trace'
|
||||
|
||||
import { CaptchaVerify, get, put, remove, update } from '@utils/Query'
|
||||
@ -84,12 +84,25 @@ const Bots = RequestHandler()
|
||||
})
|
||||
get.botSubmits.clear(user)
|
||||
|
||||
await discordLog('BOT/SUBMIT', user, new MessageEmbed().setDescription(`[${result.id}/${result.date}](${KoreanbotsEndPoints.URL.submittedBot(result.id, result.date)})`), {
|
||||
await discordLog('BOT/SUBMIT', user, new EmbedBuilder().setDescription(`[${result.id}/${result.date}](${KoreanbotsEndPoints.URL.submittedBot(result.id, result.date)})`), {
|
||||
content: inspect(serialize(result)),
|
||||
format: 'js'
|
||||
})
|
||||
const userinfo = await get.user.load(user)
|
||||
await getBotReviewLogChannel().send(new MessageEmbed().setAuthor(`${userinfo.username}#${userinfo.tag}`, KoreanbotsEndPoints.URL.root + KoreanbotsEndPoints.CDN.avatar(userinfo.id, { format: 'png', size: 256 }), KoreanbotsEndPoints.URL.user(userinfo.id)).setTitle('대기 중').setColor('GREY').setDescription(`[${result.id}/${result.date}](${KoreanbotsEndPoints.URL.submittedBot(result.id, result.date)})`).setTimestamp())
|
||||
await getBotReviewLogChannel().send({
|
||||
embeds: [
|
||||
new EmbedBuilder()
|
||||
.setAuthor({
|
||||
name: `${userinfo.username}#${userinfo.tag}`,
|
||||
iconURL: KoreanbotsEndPoints.URL.root + KoreanbotsEndPoints.CDN.avatar(userinfo.id, { format: 'png', size: 256 }),
|
||||
url: KoreanbotsEndPoints.URL.user(userinfo.id)
|
||||
})
|
||||
.setTitle('대기 중')
|
||||
.setColor(Colors.Grey)
|
||||
.setDescription(`[${result.id}/${result.date}](${KoreanbotsEndPoints.URL.submittedBot(result.id, result.date)})`)
|
||||
.setTimestamp()
|
||||
]
|
||||
})
|
||||
tracer.trace('botSubmits.submitted', span => {
|
||||
span.setTag('id', result.id)
|
||||
span.setTag('date', result.date)
|
||||
@ -113,7 +126,7 @@ const Bots = RequestHandler()
|
||||
await remove.bot(bot.id)
|
||||
await getMainGuild().members.cache.get(bot.id)?.kick('봇 삭제됨.')
|
||||
get.user.clear(user)
|
||||
await discordLog('BOT/DELETE', user, (new MessageEmbed().setDescription(`${bot.name} - <@${bot.id}> ([${bot.id}](${KoreanbotsEndPoints.URL.bot(bot.id)}))`)),
|
||||
await discordLog('BOT/DELETE', user, (new EmbedBuilder().setDescription(`${bot.name} - <@${bot.id}> ([${bot.id}](${KoreanbotsEndPoints.URL.bot(bot.id)}))`)),
|
||||
{
|
||||
content: inspect(bot),
|
||||
format: 'js'
|
||||
@ -144,13 +157,14 @@ const Bots = RequestHandler()
|
||||
if(result === 0) return ResponseWrapper(res, { code: 400 })
|
||||
else {
|
||||
get.bot.clear(req.query.id)
|
||||
const embed = new MessageEmbed().setDescription(`${bot.name} - <@${bot.id}> ([${bot.id}](${KoreanbotsEndPoints.URL.bot(bot.id)}))`)
|
||||
const embed = new EmbedBuilder().setDescription(`${bot.name} - <@${bot.id}> ([${bot.id}](${KoreanbotsEndPoints.URL.bot(bot.id)}))`)
|
||||
const diffData = objectDiff(
|
||||
{ prefix: bot.prefix, library: bot.lib, web: bot.web, git: bot.git, url: bot.url, discord: bot.discord, intro: bot.intro, category: JSON.stringify(bot.category) },
|
||||
{ prefix: validated.prefix, library: validated.library, web: validated.website, git: validated.git, url: validated.url, discord: validated.discord, intro: validated.intro, category: JSON.stringify(validated.category) }
|
||||
)
|
||||
diffData.forEach(d => {
|
||||
embed.addField(d[0], makeDiscordCodeblock(diff(d[1][0] || '', d[1][1] || ''), 'diff'))
|
||||
embed.addFields({name: d[0], value: makeDiscordCodeblock(diff(d[1][0] || '', d[1][1] || ''), 'diff')
|
||||
})
|
||||
})
|
||||
await discordLog('BOT/EDIT', user, embed,
|
||||
{
|
||||
|
||||
@ -8,7 +8,7 @@ import { checkUserFlag, diff, makeDiscordCodeblock } from '@utils/Tools'
|
||||
import { EditBotOwner, EditBotOwnerSchema } from '@utils/Yup'
|
||||
import { User } from '@types'
|
||||
import { discordLog } from '@utils/DiscordBot'
|
||||
import { MessageEmbed } from 'discord.js'
|
||||
import { EmbedBuilder } from 'discord.js'
|
||||
import { KoreanbotsEndPoints } from '@utils/Constants'
|
||||
|
||||
const BotOwners = RequestHandler()
|
||||
@ -36,7 +36,7 @@ const BotOwners = RequestHandler()
|
||||
if(userFetched.length > 1 && userFetched[0].id !== (bot.owners as User[])[0].id) return ResponseWrapper(res, { code: 400, errors: ['소유자를 이전할 때는 다른 관리자를 포함할 수 없습니다.'] })
|
||||
await update.botOwners(bot.id, validated.owners)
|
||||
get.user.clear(user)
|
||||
await discordLog('BOT/OWNERS', userinfo.id, (new MessageEmbed().setDescription(`${bot.name} - <@${bot.id}> ([${bot.id}](${KoreanbotsEndPoints.URL.bot(bot.id)}))`)), null, makeDiscordCodeblock(diff(JSON.stringify(bot.owners.map(el => el.id)), JSON.stringify(validated.owners)), 'diff'))
|
||||
await discordLog('BOT/OWNERS', userinfo.id, (new EmbedBuilder().setDescription(`${bot.name} - <@${bot.id}> ([${bot.id}](${KoreanbotsEndPoints.URL.bot(bot.id)}))`)), null, makeDiscordCodeblock(diff(JSON.stringify(bot.owners.map(el => el.id)), JSON.stringify(validated.owners)), 'diff'))
|
||||
return ResponseWrapper(res, { code: 200 })
|
||||
})
|
||||
|
||||
|
||||
@ -38,7 +38,7 @@ const BotReport = RequestHandler().post(limiter)
|
||||
})
|
||||
|
||||
if(!validated) return
|
||||
await getReportChannel().send(`Reported by <@${user}> (${user})\nReported **${bot.name}** <@${bot.id}> (${bot.id})\nCategory ${req.body.category}\nDesc\n\`\`\`${req.body.description}\`\`\``, { allowedMentions: { parse: ['users'] }})
|
||||
await getReportChannel().send({ content: `Reported by <@${user}> (${user})\nReported **${bot.name}** <@${bot.id}> (${bot.id})\nCategory ${req.body.category}\nDesc\n\`\`\`${req.body.description}\`\`\``, allowedMentions: { parse: ['users'] }})
|
||||
return ResponseWrapper(res, { code: 200, message: '성공적으로 처리되었습니다.' })
|
||||
})
|
||||
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { NextApiRequest } from 'next'
|
||||
import rateLimit from 'express-rate-limit'
|
||||
import { MessageEmbed } from 'discord.js'
|
||||
import { EmbedBuilder } from 'discord.js'
|
||||
|
||||
import { get, update } from '@utils/Query'
|
||||
import RequestHandler from '@utils/RequestHandler'
|
||||
@ -57,7 +57,10 @@ const BotStats = RequestHandler().post(limiter)
|
||||
const d = await update.updateServer(botInfo.id, validated.servers, validated.shards)
|
||||
if(d===1 || d===2) return ResponseWrapper(res, { code: 403, message: `서버 수를 ${[null, '1만', '100만'][d]} 이상으로 설정하실 수 없습니다. 문의해주세요.` })
|
||||
get.bot.clear(req.query.id)
|
||||
await getStatsLoggingChannel().send(`[BOT/STATS] <@${botInfo.id}> (${botInfo.id})\n${makeDiscordCodeblock(`${botInfo.servers > validated.servers ? '-' : '+'} ${botInfo.servers} -> ${validated.servers} (${botInfo.servers > validated.servers ? '▼' : '▲'}${Math.abs(validated.servers - botInfo.servers)})`, 'diff')}`, (new MessageEmbed().setDescription(`${botInfo.name} - <@${botInfo.id}> ([${botInfo.id}](${KoreanbotsEndPoints.URL.bot(botInfo.id)}))`)))
|
||||
await getStatsLoggingChannel().send({
|
||||
content: `[BOT/STATS] <@${botInfo.id}> (${botInfo.id})\n${makeDiscordCodeblock(`${botInfo.servers > validated.servers ? '-' : '+'} ${botInfo.servers} -> ${validated.servers} (${botInfo.servers > validated.servers ? '▼' : '▲'}${Math.abs(validated.servers - botInfo.servers)})`, 'diff')}`,
|
||||
embeds: [new EmbedBuilder().setDescription(`${botInfo.name} - <@${botInfo.id}> ([${botInfo.id}](${KoreanbotsEndPoints.URL.bot(botInfo.id)}))`)]
|
||||
})
|
||||
return ResponseWrapper(res, { code: 200, message: '성공적으로 업데이트 했습니다.'})
|
||||
})
|
||||
.patch(patchLimiter).patch(async (req: ApiRequest, res) => {
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { NextApiRequest } from 'next'
|
||||
import { MessageEmbed } from 'discord.js'
|
||||
import { Colors, EmbedBuilder } from 'discord.js'
|
||||
import tracer from 'dd-trace'
|
||||
|
||||
import RequestHandler from '@utils/RequestHandler'
|
||||
@ -19,9 +19,9 @@ const ApproveBotSubmit = RequestHandler()
|
||||
if(!result) return ResponseWrapper(res, { code: 400 })
|
||||
get.botSubmit.clear(JSON.stringify({ id: req.query.id, date: req.query.date }))
|
||||
get.bot.clear(req.query.id)
|
||||
const embed = new MessageEmbed().setTitle('승인').setColor('GREEN').setDescription(`[${submit.id}/${submit.date}](${KoreanbotsEndPoints.URL.submittedBot(submit.id, submit.date)})`).setTimestamp()
|
||||
if(req.body.reviewer) embed.addField('📃 정보', `심사자: ${req.body.reviewer}`)
|
||||
await getBotReviewLogChannel().send(embed)
|
||||
const embed = new EmbedBuilder().setTitle('승인').setColor(Colors.Green).setDescription(`[${submit.id}/${submit.date}](${KoreanbotsEndPoints.URL.submittedBot(submit.id, submit.date)})`).setTimestamp()
|
||||
if(req.body.reviewer) embed.addFields({name: '📃 정보', value: `심사자: ${req.body.reviewer}`})
|
||||
await getBotReviewLogChannel().send({embeds: [embed]})
|
||||
tracer.trace('botSubmits.approve', span => {
|
||||
span.setTag('id', submit.id)
|
||||
span.setTag('date', submit.date)
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { NextApiRequest } from 'next'
|
||||
import { MessageEmbed } from 'discord.js'
|
||||
import { Colors, EmbedBuilder } from 'discord.js'
|
||||
import tracer from 'dd-trace'
|
||||
|
||||
import RequestHandler from '@utils/RequestHandler'
|
||||
@ -17,12 +17,12 @@ const DenyBotSubmit = RequestHandler()
|
||||
if(submit.state !== 0) return ResponseWrapper(res, { code: 400, message: '대기 중이지 않은 아이디입니다.' })
|
||||
await update.denyBotSubmission(submit.id, submit.date, req.body.reason)
|
||||
get.botSubmit.clear(JSON.stringify({ id: req.query.id, date: req.query.date }))
|
||||
const embed = new MessageEmbed().setTitle('거부').setColor('RED').setDescription(`[${submit.id}/${submit.date}](${KoreanbotsEndPoints.URL.submittedBot(submit.id, submit.date)})`).setTimestamp()
|
||||
if(req.body.reviewer || req.body.reason) embed.addField('📃 정보', `${req.body.reason ? `사유: ${BotSubmissionDenyReasonPresetsName[req.body.reason] || req.body.reason}\n`: ''}${req.body.reviewer ? `심사자: ${req.body.reviewer}` : ''}`)
|
||||
await getBotReviewLogChannel().send(embed)
|
||||
const openEmbed = new MessageEmbed().setTitle('거부').setColor('RED').setDescription(`<@${submit.id}> (${submit.id})`).setTimestamp()
|
||||
if(req.body.reason) openEmbed.addField('📃 사유', `${req.body.reason ? `${BotSubmissionDenyReasonPresetsName[req.body.reason] || req.body.reason}\n`: '없음'}`)
|
||||
await getOpenBotReviewLogChannel().send(openEmbed)
|
||||
const embed = new EmbedBuilder().setTitle('거부').setColor(Colors.Red).setDescription(`[${submit.id}/${submit.date}](${KoreanbotsEndPoints.URL.submittedBot(submit.id, submit.date)})`).setTimestamp()
|
||||
if(req.body.reviewer || req.body.reason) embed.addFields({name: '📃 정보', value: `${req.body.reason ? `사유: ${BotSubmissionDenyReasonPresetsName[req.body.reason] || req.body.reason}\n`: ''}${req.body.reviewer ? `심사자: ${req.body.reviewer}` : ''}`})
|
||||
await getBotReviewLogChannel().send({embeds: [embed]})
|
||||
const openEmbed = new EmbedBuilder().setTitle('거부').setColor(Colors.Red).setDescription(`<@${submit.id}> (${submit.id})`).setTimestamp()
|
||||
if(req.body.reason) openEmbed.addFields({name: '📃 사유', value: `${req.body.reason ? `${BotSubmissionDenyReasonPresetsName[req.body.reason] || req.body.reason}\n`: '없음'}`})
|
||||
await getOpenBotReviewLogChannel().send({embeds: [openEmbed]})
|
||||
tracer.trace('botSubmits.deny', span => {
|
||||
span.setTag('id', submit.id)
|
||||
span.setTag('date', submit.date)
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { NextApiRequest } from 'next'
|
||||
import rateLimit from 'express-rate-limit'
|
||||
import { MessageEmbed } from 'discord.js'
|
||||
import { EmbedBuilder } from 'discord.js'
|
||||
|
||||
import { CaptchaVerify, get, put, remove, update } from '@utils/Query'
|
||||
import ResponseWrapper from '@utils/ResponseWrapper'
|
||||
@ -76,7 +76,7 @@ const Servers = RequestHandler()
|
||||
],
|
||||
})
|
||||
get.user.clear(user)
|
||||
await discordLog('SERVER/SUBMIT', user, new MessageEmbed().setDescription(`[${req.query.id}](${KoreanbotsEndPoints.URL.server(req.query.id)})`), {
|
||||
await discordLog('SERVER/SUBMIT', user, new EmbedBuilder().setDescription(`[${req.query.id}](${KoreanbotsEndPoints.URL.server(req.query.id)})`), {
|
||||
content: inspect(serialize(validated)),
|
||||
format: 'js'
|
||||
})
|
||||
@ -100,7 +100,7 @@ const Servers = RequestHandler()
|
||||
if(req.body.name !== server.name) return ResponseWrapper(res, { code: 400, message: '봇 이름을 입력해주세요.' })
|
||||
await remove.server(server.id)
|
||||
get.user.clear(user)
|
||||
await discordLog('SERVER/DELETE', user, (new MessageEmbed().setDescription(`${server.name} - [${server.id}](${KoreanbotsEndPoints.URL.bot(server.id)}))`)),
|
||||
await discordLog('SERVER/DELETE', user, (new EmbedBuilder().setDescription(`${server.name} - [${server.id}](${KoreanbotsEndPoints.URL.bot(server.id)}))`)),
|
||||
{
|
||||
content: inspect(server),
|
||||
format: 'js'
|
||||
@ -135,13 +135,14 @@ const Servers = RequestHandler()
|
||||
if(result === 0) return ResponseWrapper(res, { code: 400 })
|
||||
else {
|
||||
get.server.clear(req.query.id)
|
||||
const embed = new MessageEmbed().setDescription(`${server.name} - ([${server.id}](${KoreanbotsEndPoints.URL.server(server.id)}))`)
|
||||
const embed = new EmbedBuilder().setDescription(`${server.name} - ([${server.id}](${KoreanbotsEndPoints.URL.server(server.id)}))`)
|
||||
const diffData = objectDiff(
|
||||
{ intro: server.intro, invite: server.invite, category: JSON.stringify(server.category) },
|
||||
{ intro: validated.intro, invite: validated.invite, category: JSON.stringify(validated.category) },
|
||||
)
|
||||
diffData.forEach(d => {
|
||||
embed.addField(d[0], makeDiscordCodeblock(diff(d[1][0] || '', d[1][1] || ''), 'diff'))
|
||||
embed.addFields({name: d[0], value: makeDiscordCodeblock(diff(d[1][0] || '', d[1][1] || ''), 'diff')
|
||||
})
|
||||
})
|
||||
await discordLog('SERVER/EDIT', user, embed,
|
||||
{
|
||||
|
||||
@ -38,7 +38,7 @@ const ServerReport = RequestHandler().post(limiter)
|
||||
})
|
||||
|
||||
if(!validated) return
|
||||
await getReportChannel().send(`Reported by <@${user}> (${user})\nReported **${server.name}** (${server.id})\nCategory ${req.body.category}\nDesc\n\`\`\`${req.body.description}\`\`\``, { allowedMentions: { parse: ['users'] }})
|
||||
await getReportChannel().send({content: `Reported by <@${user}> (${user})\nReported **${server.name}** (${server.id})\nCategory ${req.body.category}\nDesc\n\`\`\`${req.body.description}\`\`\``, allowedMentions: { parse: ['users'] }})
|
||||
return ResponseWrapper(res, { code: 200, message: '성공적으로 처리되었습니다.' })
|
||||
})
|
||||
|
||||
|
||||
@ -37,7 +37,7 @@ const UserReport = RequestHandler().post(limiter)
|
||||
})
|
||||
|
||||
if(!validated) return
|
||||
await getReportChannel().send(`Reported by <@${user}> (${user})\nReported **${userInfo.username}**#${userInfo.tag} <@${userInfo.id}> (${userInfo.id})\nCategory ${req.body.category}\nDesc\n\`\`\`${req.body.description}\`\`\``, { allowedMentions: { parse: ['users'] }})
|
||||
await getReportChannel().send({ content: `Reported by <@${user}> (${user})\nReported **${userInfo.username}**#${userInfo.tag} <@${userInfo.id}> (${userInfo.id})\nCategory ${req.body.category}\nDesc\n\`\`\`${req.body.description}\`\`\``, allowedMentions: { parse: ['users'] }})
|
||||
return ResponseWrapper(res, { code: 200, message: '성공적으로 처리되었습니다.' })
|
||||
})
|
||||
|
||||
|
||||
@ -356,7 +356,7 @@ export const getServerSideProps = async (ctx: Context) => {
|
||||
props: {
|
||||
data,
|
||||
desc,
|
||||
date: SnowflakeUtil.deconstruct(data.id ?? '0').date.toJSON(),
|
||||
date: Number(SnowflakeUtil.deconstruct(data.id ?? '0').timestamp),
|
||||
user: await get.user.load(user || ''),
|
||||
csrfToken: getToken(ctx.req, ctx.res)
|
||||
},
|
||||
|
||||
@ -291,7 +291,7 @@ export const getServerSideProps = async (ctx: Context) => {
|
||||
props: {
|
||||
data,
|
||||
desc,
|
||||
date: SnowflakeUtil.deconstruct(data.id ?? '0').date.toJSON(),
|
||||
date: Number(SnowflakeUtil.deconstruct(data.id ?? '0').timestamp),
|
||||
user: await get.user.load(user || ''),
|
||||
csrfToken: getToken(ctx.req, ctx.res)
|
||||
},
|
||||
|
||||
@ -135,7 +135,7 @@ export const getServerSideProps = async (ctx: Context) => {
|
||||
|
||||
const user = await get.Authorization(parsed?.token) || ''
|
||||
const data = await get.user.load(ctx.query.id)
|
||||
return { props: { user: await get.user.load(user) || {}, data, date: SnowflakeUtil.deconstruct(data?.id ?? '0')?.date?.toJSON(), csrfToken: getToken(ctx.req, ctx.res) } }
|
||||
return { props: { user: await get.user.load(user) || {}, data, date: Number(SnowflakeUtil.deconstruct(data?.id ?? '0')?.timestamp), csrfToken: getToken(ctx.req, ctx.res) } }
|
||||
}
|
||||
|
||||
interface UserProps {
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
import type { GuildFeatures } from 'discord.js'
|
||||
import type { GuildFeature } from 'discord.js'
|
||||
import type { IncomingMessage } from 'http'
|
||||
import type { NextPageContext } from 'next'
|
||||
|
||||
@ -36,7 +36,7 @@ export interface RawGuild {
|
||||
icon: string
|
||||
owner: boolean
|
||||
permissions: number
|
||||
features: GuildFeatures[]
|
||||
features: GuildFeature[]
|
||||
}
|
||||
|
||||
export interface Server {
|
||||
@ -95,7 +95,7 @@ export interface ServerData {
|
||||
bots: string[]
|
||||
memberCount: number
|
||||
boostTier: number
|
||||
features: GuildFeatures[]
|
||||
features: GuildFeature[]
|
||||
emojis: ServerEmojiData[]
|
||||
}
|
||||
|
||||
|
||||
@ -1,6 +1,8 @@
|
||||
import * as Discord from 'discord.js'
|
||||
|
||||
export const DiscordBot = new Discord.Client()
|
||||
export const DiscordBot = new Discord.Client({
|
||||
intents: Number(process.env.DISCORD_CLIENT_INTENTS ?? 32767)
|
||||
})
|
||||
|
||||
const guildID = '653083797763522580'
|
||||
|
||||
@ -28,13 +30,12 @@ export const getBotReviewLogChannel = (): Discord.TextChannel => getReviewGuild(
|
||||
export const getStatsLoggingChannel = (): Discord.TextChannel => getMainGuild().channels.cache.get(statsLoggingChannelID) as Discord.TextChannel
|
||||
export const getOpenBotReviewLogChannel = (): Discord.TextChannel => getMainGuild().channels.cache.get(openBotReviewLogChannelID) as Discord.TextChannel
|
||||
|
||||
export const discordLog = async (type: string, issuerID: string, embed?: Discord.MessageEmbed, attachment?: { content: string, format: string}, content?: string): Promise<void> => {
|
||||
export const discordLog = async (type: string, issuerID: string, embed?: Discord.EmbedBuilder, attachment?: { content: string, format: string}, content?: string): Promise<void> => {
|
||||
getLoggingChannel().send({
|
||||
content: `[${type}] <@${issuerID}> (${issuerID})\n${content || ''}`,
|
||||
embed: embed && embed.setTitle(type).setTimestamp(new Date()),
|
||||
embeds: [embed && embed.setTitle(type).setTimestamp(new Date())],
|
||||
...(attachment && { files: [
|
||||
new Discord.MessageAttachment(Buffer.from(attachment.content), `${type.toLowerCase().replace(/\//g, '-')}-${issuerID}-${Date.now()}.${attachment.format}`)
|
||||
]
|
||||
})
|
||||
new Discord.AttachmentBuilder(Buffer.from(attachment.content), {name: `${type.toLowerCase().replace(/\//g, '-')}-${issuerID}-${Date.now()}.${attachment.format}`
|
||||
})]})
|
||||
})
|
||||
}
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
import fetch from 'node-fetch'
|
||||
import { TLRU } from 'tlru'
|
||||
import DataLoader from 'dataloader'
|
||||
import { User as DiscordUser } from 'discord.js'
|
||||
import { ActivityType, GuildFeature, GuildMember, User as DiscordUser } from 'discord.js'
|
||||
|
||||
import { Bot, Server, User, ListType, List, TokenRegister, BotFlags, DiscordUserFlags, SubmittedBot, DiscordTokenInfo, ServerData, ServerFlags, RawGuild, Nullable } from '@types'
|
||||
import { botCategories, DiscordEnpoints, imageSafeHost, serverCategories, SpecialEndPoints, VOTE_COOLDOWN } from './Constants'
|
||||
@ -46,16 +46,24 @@ async function getBot(id: string, topLevel=true):Promise<Bot> {
|
||||
.orWhere({ vanity: id, trusted: true })
|
||||
.orWhere({ vanity: id, partnered: true })
|
||||
if (res[0]) {
|
||||
const discordBot = await DiscordBot.users.fetch(res[0].id).then(r=> r).catch(() => null)
|
||||
const discordBot = await DiscordBot.users.fetch(res[0].id).then(r=> r).catch(() => null) as DiscordUser
|
||||
if(!discordBot) return null
|
||||
await getMainGuild()?.members?.fetch(res[0].id).catch(e=> e)
|
||||
const botMember = await getMainGuild()?.members?.fetch(res[0].id).catch(e=> e) as GuildMember
|
||||
res[0].flags = res[0].flags | (discordBot.flags?.bitfield && DiscordUserFlags.VERIFIED_BOT ? BotFlags.verified : 0) | (res[0].trusted ? BotFlags.trusted : 0) | (res[0].partnered ? BotFlags.partnered : 0)
|
||||
res[0].tag = discordBot.discriminator
|
||||
res[0].avatar = discordBot.avatar
|
||||
res[0].name = discordBot.username
|
||||
res[0].category = JSON.parse(res[0].category)
|
||||
res[0].owners = JSON.parse(res[0].owners)
|
||||
res[0].status = discordBot.presence?.activities?.find(r => r.type === 'STREAMING') ? 'streaming' : discordBot.presence?.status || null
|
||||
if(botMember) {
|
||||
if(botMember.presence === null) {
|
||||
res[0].status = 'offline'
|
||||
} else {
|
||||
res[0].status = botMember?.presence?.activities.find(r => r.type === ActivityType.Streaming) ? 'streaming' : botMember?.presence?.status || null
|
||||
}
|
||||
} else {
|
||||
res[0].status = null
|
||||
}
|
||||
delete res[0].trusted
|
||||
delete res[0].partnered
|
||||
if (topLevel) {
|
||||
@ -97,7 +105,7 @@ async function getServer(id: string, topLevel=true): Promise<Server> {
|
||||
const data = await getServerData(res[0].id)
|
||||
if(!data || (+new Date() - +new Date(data.updatedAt)) > 3 * 60 * 1000) res[0].state = 'unreachable'
|
||||
else {
|
||||
res[0].flags = res[0].flags | (data.features.includes('PARTNERED') && ServerFlags.discord_partnered) | (data.features.includes('VERIFIED') && ServerFlags.verified)
|
||||
res[0].flags = res[0].flags | (data.features.includes(GuildFeature.Partnered) && ServerFlags.discord_partnered) | (data.features.includes(GuildFeature.Verified) && ServerFlags.verified)
|
||||
if(res[0].owners !== JSON.stringify([data.owner, ...data.admins]) || res[0].name !== data.name)
|
||||
await knex('servers').update({ name: data.name, owners: JSON.stringify([data.owner, ...data.admins]) })
|
||||
.where({ id: res[0].id })
|
||||
@ -564,7 +572,7 @@ async function getImage(url: string) {
|
||||
}
|
||||
|
||||
async function getDiscordUser(id: string):Promise<DiscordUser> {
|
||||
return DiscordBot.users.cache.get(id) ?? await DiscordBot.users.fetch(id, false, true).then(u => u.toJSON()).catch(()=>null)
|
||||
return await DiscordBot.users.fetch(id, {cache: true}).then(u => u).catch(()=>null)
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
211
yarn.lock
211
yarn.lock
@ -958,19 +958,34 @@
|
||||
resolved "https://registry.yarnpkg.com/@csstools/convert-colors/-/convert-colors-1.4.0.tgz#ad495dc41b12e75d588c6db8b9834f08fa131eb7"
|
||||
integrity sha512-5a6wqoJV/xEdbRNKVo6I4hO3VjyDq//8q2f9I6PBAvMesJHFauXDorcNCsr9RzvsZnaWi5NYCcfyqP1QeFHFbw==
|
||||
|
||||
"@discordjs/collection@^0.1.6":
|
||||
version "0.1.6"
|
||||
resolved "https://registry.yarnpkg.com/@discordjs/collection/-/collection-0.1.6.tgz#9e9a7637f4e4e0688fd8b2b5c63133c91607682c"
|
||||
integrity sha512-utRNxnd9kSS2qhyivo9lMlt5qgAUasH2gb7BEOn6p0efFh24gjGomHzWKMAPn2hEReOPQZCJaRKoURwRotKucQ==
|
||||
|
||||
"@discordjs/form-data@^3.0.1":
|
||||
version "3.0.1"
|
||||
resolved "https://registry.yarnpkg.com/@discordjs/form-data/-/form-data-3.0.1.tgz#5c9e6be992e2e57d0dfa0e39979a850225fb4697"
|
||||
integrity sha512-ZfFsbgEXW71Rw/6EtBdrP5VxBJy4dthyC0tpQKGKmYFImlmmrykO14Za+BiIVduwjte0jXEBlhSKf0MWbFp9Eg==
|
||||
"@discordjs/builders@^1.1.0":
|
||||
version "1.1.0"
|
||||
resolved "https://registry.yarnpkg.com/@discordjs/builders/-/builders-1.1.0.tgz#4366a4fe069238c3e6e674b74404c79f3ba76525"
|
||||
integrity sha512-EO8TSltiIc9Z1wE854wAFvv5AccqEtvjFmao9PPoxQhRaJ0hEb7FwWRTCA1jGg4ZWI3hcp4m+RET5ufZQz3rOg==
|
||||
dependencies:
|
||||
asynckit "^0.4.0"
|
||||
combined-stream "^1.0.8"
|
||||
mime-types "^2.1.12"
|
||||
"@sapphire/shapeshift" "^3.5.1"
|
||||
discord-api-types "^0.36.3"
|
||||
fast-deep-equal "^3.1.3"
|
||||
ts-mixer "^6.0.1"
|
||||
tslib "^2.4.0"
|
||||
|
||||
"@discordjs/collection@^1.0.1":
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/@discordjs/collection/-/collection-1.0.1.tgz#4acc41dfdacd6a14a7cf3109968044a2d40593dd"
|
||||
integrity sha512-5V/wswzR3r2RVYXLxxg4TvrAnBhVCNgHTXhC+OUtLoriJ072rPMHo+Iw1SS1vrCckp8Es40XM411+WkNRPaXFw==
|
||||
|
||||
"@discordjs/rest@^1.0.1":
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/@discordjs/rest/-/rest-1.0.1.tgz#5c1c379de9eb4170b4964a11ced8add1d5ae808d"
|
||||
integrity sha512-w08CTKVzzYYvKxEjXKOs9AdS7KQ1J502TrPfF8eCZ2lF6AfKuMP/32YgDakiwIyYTDjEQS/v0nKLSFcncHRMtg==
|
||||
dependencies:
|
||||
"@discordjs/collection" "^1.0.1"
|
||||
"@sapphire/async-queue" "^1.3.2"
|
||||
"@sapphire/snowflake" "^3.2.2"
|
||||
discord-api-types "^0.36.3"
|
||||
file-type "^17.1.4"
|
||||
tslib "^2.4.0"
|
||||
undici "^5.8.0"
|
||||
|
||||
"@emotion/cache@^11.4.0":
|
||||
version "11.4.0"
|
||||
@ -1523,6 +1538,24 @@
|
||||
resolved "https://registry.yarnpkg.com/@rushstack/eslint-patch/-/eslint-patch-1.0.6.tgz#023d72a5c4531b4ce204528971700a78a85a0c50"
|
||||
integrity sha512-Myxw//kzromB9yWgS8qYGuGVf91oBUUJpNvy5eM50sqvmKLbKjwLxohJnkWGTeeI9v9IBMtPLxz5Gc60FIfvCA==
|
||||
|
||||
"@sapphire/async-queue@^1.3.2":
|
||||
version "1.5.0"
|
||||
resolved "https://registry.yarnpkg.com/@sapphire/async-queue/-/async-queue-1.5.0.tgz#2f255a3f186635c4fb5a2381e375d3dfbc5312d8"
|
||||
integrity sha512-JkLdIsP8fPAdh9ZZjrbHWR/+mZj0wvKS5ICibcLrRI1j84UmLMshx5n9QmL8b95d4onJ2xxiyugTgSAX7AalmA==
|
||||
|
||||
"@sapphire/shapeshift@^3.5.1":
|
||||
version "3.5.1"
|
||||
resolved "https://registry.yarnpkg.com/@sapphire/shapeshift/-/shapeshift-3.5.1.tgz#3bfd0e6bcfdced4ac26a6f450b5f7b8e49f4f2cc"
|
||||
integrity sha512-7JFsW5IglyOIUQI1eE0g6h06D/Far6HqpcowRScgCiLSqTf3hhkPWCWotVTtVycnDCMYIwPeaw6IEPBomKC8pA==
|
||||
dependencies:
|
||||
fast-deep-equal "^3.1.3"
|
||||
lodash.uniqwith "^4.5.0"
|
||||
|
||||
"@sapphire/snowflake@^3.2.2":
|
||||
version "3.2.2"
|
||||
resolved "https://registry.yarnpkg.com/@sapphire/snowflake/-/snowflake-3.2.2.tgz#faacdc1b5f7c43145a71eddba917de2b707ef780"
|
||||
integrity sha512-ula2O0kpSZtX9rKXNeQMrHwNd7E4jPDJYUXmEGTFdMRfyfMw+FPyh04oKMjAiDuOi64bYgVkOV3MjK+loImFhQ==
|
||||
|
||||
"@sentry/browser@6.10.0":
|
||||
version "6.10.0"
|
||||
resolved "https://registry.yarnpkg.com/@sentry/browser/-/browser-6.10.0.tgz#92e72edca584d940fba80cf6477d4a54c6dea573"
|
||||
@ -1687,6 +1720,11 @@
|
||||
mini-svg-data-uri "^1.0.3"
|
||||
traverse "^0.6.6"
|
||||
|
||||
"@tokenizer/token@^0.3.0":
|
||||
version "0.3.0"
|
||||
resolved "https://registry.yarnpkg.com/@tokenizer/token/-/token-0.3.0.tgz#fe98a93fe789247e998c75e74e9c7c63217aa276"
|
||||
integrity sha512-OvjF+z51L3ov0OyAU0duzsYuvO01PH7x4t6DJx+guahgTnBHkhJdG7soQeTSFLWN3efnHyibZ4Z8l2EuWwJN3A==
|
||||
|
||||
"@tootallnate/once@1":
|
||||
version "1.1.2"
|
||||
resolved "https://registry.yarnpkg.com/@tootallnate/once/-/once-1.1.2.tgz#ccb91445360179a04e7fe6aff78c00ffc1eeaf82"
|
||||
@ -2069,6 +2107,13 @@
|
||||
anymatch "^3.0.0"
|
||||
source-map "^0.6.0"
|
||||
|
||||
"@types/ws@^8.5.3":
|
||||
version "8.5.3"
|
||||
resolved "https://registry.yarnpkg.com/@types/ws/-/ws-8.5.3.tgz#7d25a1ffbecd3c4f2d35068d0b283c037003274d"
|
||||
integrity sha512-6YOoWjruKj1uLf3INHH7D3qTXwFfEsg1kf3c0uDdSBJwfa/llkwIjrAGV7j7mVgGNbzTQ3HiHKKDXl6bJPD97w==
|
||||
dependencies:
|
||||
"@types/node" "*"
|
||||
|
||||
"@types/yargs-parser@*":
|
||||
version "20.2.1"
|
||||
resolved "https://registry.yarnpkg.com/@types/yargs-parser/-/yargs-parser-20.2.1.tgz#3b9ce2489919d9e4fea439b76916abc34b2df129"
|
||||
@ -2211,7 +2256,7 @@ abbrev@1:
|
||||
resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8"
|
||||
integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==
|
||||
|
||||
abort-controller@3.0.0, abort-controller@^3.0.0:
|
||||
abort-controller@3.0.0:
|
||||
version "3.0.0"
|
||||
resolved "https://registry.yarnpkg.com/abort-controller/-/abort-controller-3.0.0.tgz#eaf54d53b62bae4138e809ca225c8439a6efb392"
|
||||
integrity sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==
|
||||
@ -3708,19 +3753,27 @@ dir-glob@^3.0.1:
|
||||
dependencies:
|
||||
path-type "^4.0.0"
|
||||
|
||||
discord.js@12.5.3:
|
||||
version "12.5.3"
|
||||
resolved "https://registry.yarnpkg.com/discord.js/-/discord.js-12.5.3.tgz#56820d473c24320871df9ea0bbc6b462f21cf85c"
|
||||
integrity sha512-D3nkOa/pCkNyn6jLZnAiJApw2N9XrIsXUAdThf01i7yrEuqUmDGc7/CexVWwEcgbQR97XQ+mcnqJpmJ/92B4Aw==
|
||||
discord-api-types@^0.36.3:
|
||||
version "0.36.3"
|
||||
resolved "https://registry.yarnpkg.com/discord-api-types/-/discord-api-types-0.36.3.tgz#a931b7e57473a5c971d6937fa5f392eb30047579"
|
||||
integrity sha512-bz/NDyG0KBo/tY14vSkrwQ/n3HKPf87a0WFW/1M9+tXYK+vp5Z5EksawfCWo2zkAc6o7CClc0eff1Pjrqznlwg==
|
||||
|
||||
discord.js@^14.2.0:
|
||||
version "14.2.0"
|
||||
resolved "https://registry.yarnpkg.com/discord.js/-/discord.js-14.2.0.tgz#42f5669a267bf29f355f4b2b8db02bd84c40a601"
|
||||
integrity sha512-kIGhEeOB1d9k7whL9HCCuRuzK2GL7i/hTesYINOZ2szWm4TOsBVwRU+i9O/zDb2M+Gvff4SJ4EpAtCVV0okgVw==
|
||||
dependencies:
|
||||
"@discordjs/collection" "^0.1.6"
|
||||
"@discordjs/form-data" "^3.0.1"
|
||||
abort-controller "^3.0.0"
|
||||
node-fetch "^2.6.1"
|
||||
prism-media "^1.2.9"
|
||||
setimmediate "^1.0.5"
|
||||
tweetnacl "^1.0.3"
|
||||
ws "^7.4.4"
|
||||
"@discordjs/builders" "^1.1.0"
|
||||
"@discordjs/collection" "^1.0.1"
|
||||
"@discordjs/rest" "^1.0.1"
|
||||
"@sapphire/snowflake" "^3.2.2"
|
||||
"@types/ws" "^8.5.3"
|
||||
discord-api-types "^0.36.3"
|
||||
fast-deep-equal "^3.1.3"
|
||||
lodash.snakecase "^4.1.1"
|
||||
tslib "^2.4.0"
|
||||
undici "^5.8.2"
|
||||
ws "^8.8.1"
|
||||
|
||||
dlv@^1.1.3:
|
||||
version "1.1.3"
|
||||
@ -3898,13 +3951,13 @@ env-paths@^2.2.0:
|
||||
resolved "https://registry.yarnpkg.com/env-paths/-/env-paths-2.2.1.tgz#420399d416ce1fbe9bc0a07c62fa68d67fd0f8f2"
|
||||
integrity sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==
|
||||
|
||||
erlpack@0.1.3:
|
||||
version "0.1.3"
|
||||
resolved "https://registry.yarnpkg.com/erlpack/-/erlpack-0.1.3.tgz#f6cd2a0d5b2f9d054b310c1dda98f60744b9f857"
|
||||
integrity sha512-QeG9v8CVsY/a/IoQi8zjn23aYKcziOihAxwjUl3tI/KB4R1FjTtctDAAMovgtpC16S+WiOauers2oWwIOQtKBQ==
|
||||
erlpack@0.1.4:
|
||||
version "0.1.4"
|
||||
resolved "https://registry.yarnpkg.com/erlpack/-/erlpack-0.1.4.tgz#018758a53206b8e9ba1f6c58a6766e3ba261a113"
|
||||
integrity sha512-CJYbkEvsB5FqCCu2tLxF1eYKi28PvemC12oqzJ9oO6mDFrFO9G9G7nNJUHhiAyyL9zfXTOJx/tOcrQk+ncD65w==
|
||||
dependencies:
|
||||
bindings "^1.5.0"
|
||||
nan "^2.14.0"
|
||||
nan "^2.15.0"
|
||||
|
||||
err-code@^2.0.2:
|
||||
version "2.0.3"
|
||||
@ -4360,6 +4413,15 @@ file-entry-cache@^6.0.1:
|
||||
dependencies:
|
||||
flat-cache "^3.0.4"
|
||||
|
||||
file-type@^17.1.4:
|
||||
version "17.1.6"
|
||||
resolved "https://registry.yarnpkg.com/file-type/-/file-type-17.1.6.tgz#18669e0577a4849ef6e73a41f8bdf1ab5ae21023"
|
||||
integrity sha512-hlDw5Ev+9e883s0pwUsuuYNu4tD7GgpUnOvykjv1Gya0ZIjuKumthDRua90VUn6/nlRKAjcxLUnHNTIUWwWIiw==
|
||||
dependencies:
|
||||
readable-web-to-node-stream "^3.0.2"
|
||||
strtok3 "^7.0.0-alpha.9"
|
||||
token-types "^5.0.0-alpha.2"
|
||||
|
||||
file-uri-to-path@1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz#553a7b8446ff6f684359c445f1e37a05dacc33dd"
|
||||
@ -4846,7 +4908,7 @@ iconv-lite@^0.6.2:
|
||||
dependencies:
|
||||
safer-buffer ">= 2.1.2 < 3.0.0"
|
||||
|
||||
ieee754@^1.1.4:
|
||||
ieee754@^1.1.4, ieee754@^1.2.1:
|
||||
version "1.2.1"
|
||||
resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352"
|
||||
integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==
|
||||
@ -6129,6 +6191,11 @@ lodash.pick@^4.4.0:
|
||||
resolved "https://registry.yarnpkg.com/lodash.pick/-/lodash.pick-4.4.0.tgz#52f05610fff9ded422611441ed1fc123a03001b3"
|
||||
integrity sha1-UvBWEP/53tQiYRRB7R/BI6AwAbM=
|
||||
|
||||
lodash.snakecase@^4.1.1:
|
||||
version "4.1.1"
|
||||
resolved "https://registry.yarnpkg.com/lodash.snakecase/-/lodash.snakecase-4.1.1.tgz#39d714a35357147837aefd64b5dcbb16becd8f8d"
|
||||
integrity sha512-QZ1d4xoBHYUeuouhEq3lk3Uq7ldgyFXGBhg04+oRLnIz8o9T65Eh+8YdroUwn846zchkA9yDsDl5CVVaV2nqYw==
|
||||
|
||||
lodash.sortby@^4.7.0:
|
||||
version "4.7.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.sortby/-/lodash.sortby-4.7.0.tgz#edd14c824e2cc9c1e0b0a1b42bb5210516a42438"
|
||||
@ -6154,6 +6221,11 @@ lodash.uniq@^4.5.0:
|
||||
resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773"
|
||||
integrity sha1-0CJTc662Uq3BvILklFM5qEJ1R3M=
|
||||
|
||||
lodash.uniqwith@^4.5.0:
|
||||
version "4.5.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.uniqwith/-/lodash.uniqwith-4.5.0.tgz#7a0cbf65f43b5928625a9d4d0dc54b18cadc7ef3"
|
||||
integrity sha512-7lYL8bLopMoy4CTICbxygAUq6CdRJ36vFc80DucPueUee+d5NBRxz3FdT9Pes/HEx5mPoT9jwnsEJWz1N7uq7Q==
|
||||
|
||||
lodash@4.x, lodash@^4.17.11, lodash@^4.17.19, lodash@^4.17.20, lodash@^4.17.21, lodash@^4.7.0:
|
||||
version "4.17.21"
|
||||
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c"
|
||||
@ -6515,6 +6587,11 @@ nan@^2.12.1, nan@^2.14.0, nan@^2.14.2:
|
||||
resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.2.tgz#f5376400695168f4cc694ac9393d0c9585eeea19"
|
||||
integrity sha512-M2ufzIiINKCuDfBSAUr1vWQ+vuVcA9kqx8JJUsbQi6yf1uGRyb7HfpdfUr5qLXf3B/t8dPvcjhKMmlfnP47EzQ==
|
||||
|
||||
nan@^2.15.0:
|
||||
version "2.16.0"
|
||||
resolved "https://registry.yarnpkg.com/nan/-/nan-2.16.0.tgz#664f43e45460fb98faf00edca0bb0d7b8dce7916"
|
||||
integrity sha512-UdAqHyFngu7TfQKsCBgAA6pWDkT8MAO7d0jyOecVhN5354xbLqdn8mV9Tat9gepAupm0bt2DbeaSC8vS52MuFA==
|
||||
|
||||
nanoclone@^0.2.1:
|
||||
version "0.2.1"
|
||||
resolved "https://registry.yarnpkg.com/nanoclone/-/nanoclone-0.2.1.tgz#dd4090f8f1a110d26bb32c49ed2f5b9235209ed4"
|
||||
@ -6637,7 +6714,7 @@ node-emoji@1.10.0, node-emoji@^1.8.1:
|
||||
dependencies:
|
||||
lodash.toarray "^4.4.0"
|
||||
|
||||
node-fetch@2.6.1, node-fetch@^2.6.0, node-fetch@^2.6.1:
|
||||
node-fetch@2.6.1, node-fetch@^2.6.0:
|
||||
version "2.6.1"
|
||||
resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.1.tgz#045bd323631f76ed2e2b55573394416b639a0052"
|
||||
integrity sha512-V4aYg89jEoVRxRb2fJdAg8FHvI7cEyYdVAh94HH0UIK8oJxUfkjlDQN9RbMx+bEjP7+ggMiFRprSti032Oipxw==
|
||||
@ -7151,6 +7228,11 @@ pbkdf2@^3.0.3:
|
||||
safe-buffer "^5.0.1"
|
||||
sha.js "^2.4.8"
|
||||
|
||||
peek-readable@^5.0.0:
|
||||
version "5.0.0"
|
||||
resolved "https://registry.yarnpkg.com/peek-readable/-/peek-readable-5.0.0.tgz#7ead2aff25dc40458c60347ea76cfdfd63efdfec"
|
||||
integrity sha512-YtCKvLUOvwtMGmrniQPdO7MwPjgkFBtFIrmfSbYmYuq3tKDV/mcfAhBth1+C3ru7uXIZasc/pHnb+YDYNkkj4A==
|
||||
|
||||
performance-now@^2.1.0:
|
||||
version "2.1.0"
|
||||
resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b"
|
||||
@ -7654,11 +7736,6 @@ pretty-hrtime@^1.0.3:
|
||||
resolved "https://registry.yarnpkg.com/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz#b7e3ea42435a4c9b2759d99e0f201eb195802ee1"
|
||||
integrity sha1-t+PqQkNaTJsnWdmeDyAesZWALuE=
|
||||
|
||||
prism-media@^1.2.9:
|
||||
version "1.3.1"
|
||||
resolved "https://registry.yarnpkg.com/prism-media/-/prism-media-1.3.1.tgz#418acd2b122bedea2e834056d678f9a5ad2943ae"
|
||||
integrity sha512-nyYAa3KB4qteJIqdguKmwxTJgy55xxUtkJ3uRnOvO5jO+frci+9zpRXw6QZVcfDeva3S654fU9+26P2OSTzjHw==
|
||||
|
||||
process-nextick-args@~2.0.0:
|
||||
version "2.0.1"
|
||||
resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2"
|
||||
@ -8085,6 +8162,13 @@ readable-stream@^3.5.0, readable-stream@^3.6.0:
|
||||
string_decoder "^1.1.1"
|
||||
util-deprecate "^1.0.1"
|
||||
|
||||
readable-web-to-node-stream@^3.0.2:
|
||||
version "3.0.2"
|
||||
resolved "https://registry.yarnpkg.com/readable-web-to-node-stream/-/readable-web-to-node-stream-3.0.2.tgz#5d52bb5df7b54861fd48d015e93a2cb87b3ee0bb"
|
||||
integrity sha512-ePeK6cc1EcKLEhJFt/AebMCLL+GgSKhuygrZ/GLaKZYEecIgIECf4UaUuaByiGtzckwR4ain9VzUh95T1exYGw==
|
||||
dependencies:
|
||||
readable-stream "^3.6.0"
|
||||
|
||||
readdir-scoped-modules@^1.0.0:
|
||||
version "1.1.0"
|
||||
resolved "https://registry.yarnpkg.com/readdir-scoped-modules/-/readdir-scoped-modules-1.1.0.tgz#8d45407b4f870a0dcaebc0e28670d18e74514309"
|
||||
@ -8443,7 +8527,7 @@ set-blocking@^2.0.0, set-blocking@~2.0.0:
|
||||
resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7"
|
||||
integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc=
|
||||
|
||||
setimmediate@^1.0.4, setimmediate@^1.0.5:
|
||||
setimmediate@^1.0.4:
|
||||
version "1.0.5"
|
||||
resolved "https://registry.yarnpkg.com/setimmediate/-/setimmediate-1.0.5.tgz#290cbb232e306942d7d7ea9b83732ab7856f8285"
|
||||
integrity sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU=
|
||||
@ -8930,6 +9014,14 @@ strip-json-comments@^3.1.0, strip-json-comments@^3.1.1:
|
||||
resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006"
|
||||
integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==
|
||||
|
||||
strtok3@^7.0.0-alpha.9:
|
||||
version "7.0.0"
|
||||
resolved "https://registry.yarnpkg.com/strtok3/-/strtok3-7.0.0.tgz#868c428b4ade64a8fd8fee7364256001c1a4cbe5"
|
||||
integrity sha512-pQ+V+nYQdC5H3Q7qBZAz/MO6lwGhoC2gOAjuouGf/VO0m7vQRh8QNMl2Uf6SwAtzZ9bOw3UIeBukEGNJl5dtXQ==
|
||||
dependencies:
|
||||
"@tokenizer/token" "^0.3.0"
|
||||
peek-readable "^5.0.0"
|
||||
|
||||
styled-jsx@4.0.1:
|
||||
version "4.0.1"
|
||||
resolved "https://registry.yarnpkg.com/styled-jsx/-/styled-jsx-4.0.1.tgz#ae3f716eacc0792f7050389de88add6d5245b9e9"
|
||||
@ -9216,6 +9308,14 @@ toidentifier@1.0.0:
|
||||
resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.0.tgz#7e1be3470f1e77948bc43d94a3c8f4d7752ba553"
|
||||
integrity sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==
|
||||
|
||||
token-types@^5.0.0-alpha.2:
|
||||
version "5.0.1"
|
||||
resolved "https://registry.yarnpkg.com/token-types/-/token-types-5.0.1.tgz#aa9d9e6b23c420a675e55413b180635b86a093b4"
|
||||
integrity sha512-Y2fmSnZjQdDb9W4w4r1tswlMHylzWIeOKpx0aZH9BgGtACHhrk3OkT52AzwcuqTRBZtvvnTjDBh8eynMulu8Vg==
|
||||
dependencies:
|
||||
"@tokenizer/token" "^0.3.0"
|
||||
ieee754 "^1.2.1"
|
||||
|
||||
toposort@^2.0.2:
|
||||
version "2.0.2"
|
||||
resolved "https://registry.yarnpkg.com/toposort/-/toposort-2.0.2.tgz#ae21768175d1559d48bef35420b2f4962f09c330"
|
||||
@ -9277,6 +9377,11 @@ ts-jest@27.0.4:
|
||||
semver "7.x"
|
||||
yargs-parser "20.x"
|
||||
|
||||
ts-mixer@^6.0.1:
|
||||
version "6.0.1"
|
||||
resolved "https://registry.yarnpkg.com/ts-mixer/-/ts-mixer-6.0.1.tgz#7c2627fb98047eb5f3c7f2fee39d1521d18fe87a"
|
||||
integrity sha512-hvE+ZYXuINrx6Ei6D6hz+PTim0Uf++dYbK9FFifLNwQj+RwKquhQpn868yZsCtJYiclZF1u8l6WZxxKi+vv7Rg==
|
||||
|
||||
ts-pnp@^1.1.6:
|
||||
version "1.2.0"
|
||||
resolved "https://registry.yarnpkg.com/ts-pnp/-/ts-pnp-1.2.0.tgz#a500ad084b0798f1c3071af391e65912c86bca92"
|
||||
@ -9296,6 +9401,11 @@ tslib@^1.10.0, tslib@^1.8.1, tslib@^1.9.0, tslib@^1.9.3:
|
||||
resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00"
|
||||
integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==
|
||||
|
||||
tslib@^2.4.0:
|
||||
version "2.4.0"
|
||||
resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.4.0.tgz#7cecaa7f073ce680a05847aa77be941098f36dc3"
|
||||
integrity sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ==
|
||||
|
||||
tsscmp@1.0.6:
|
||||
version "1.0.6"
|
||||
resolved "https://registry.yarnpkg.com/tsscmp/-/tsscmp-1.0.6.tgz#85b99583ac3589ec4bfef825b5000aa911d605eb"
|
||||
@ -9318,11 +9428,6 @@ tty-browserify@0.0.1:
|
||||
resolved "https://registry.yarnpkg.com/tty-browserify/-/tty-browserify-0.0.1.tgz#3f05251ee17904dfd0677546670db9651682b811"
|
||||
integrity sha512-C3TaO7K81YvjCgQH9Q1S3R3P3BtN3RIM8n+OvX4il1K1zgE8ZhI0op7kClgkxtutIE8hQrcrHBXvIheqKUUCxw==
|
||||
|
||||
tweetnacl@^1.0.3:
|
||||
version "1.0.3"
|
||||
resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-1.0.3.tgz#ac0af71680458d8a6378d0d0d050ab1407d35596"
|
||||
integrity sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==
|
||||
|
||||
twemoji-parser@13.1.0:
|
||||
version "13.1.0"
|
||||
resolved "https://registry.yarnpkg.com/twemoji-parser/-/twemoji-parser-13.1.0.tgz#65e7e449c59258791b22ac0b37077349127e3ea4"
|
||||
@ -9397,10 +9502,10 @@ typedarray@^0.0.6:
|
||||
resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
|
||||
integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=
|
||||
|
||||
typescript@^4.3.5:
|
||||
version "4.3.5"
|
||||
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.3.5.tgz#4d1c37cc16e893973c45a06886b7113234f119f4"
|
||||
integrity sha512-DqQgihaQ9cUrskJo9kIyW/+g0Vxsk8cDtZ52a3NGh0YNTfpUSArXSohyUGnvbPazEPLu398C0UxmKSOrPumUzA==
|
||||
typescript@4.6.4:
|
||||
version "4.6.4"
|
||||
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.6.4.tgz#caa78bbc3a59e6a5c510d35703f6a09877ce45e9"
|
||||
integrity sha512-9ia/jWHIEbo49HfjrLGfKbZSuWo9iTMwXO+Ca3pRsSpbsMbc7/IU8NKdCZVRRBafVPGnoJeFL76ZOAA84I9fEg==
|
||||
|
||||
uid-safe@2.1.5:
|
||||
version "2.1.5"
|
||||
@ -9419,6 +9524,11 @@ unbox-primitive@^1.0.1:
|
||||
has-symbols "^1.0.2"
|
||||
which-boxed-primitive "^1.0.2"
|
||||
|
||||
undici@^5.8.0, undici@^5.8.2:
|
||||
version "5.8.2"
|
||||
resolved "https://registry.yarnpkg.com/undici/-/undici-5.8.2.tgz#071fc8a6a5d24db0ad510ad442f607d9b09d5eec"
|
||||
integrity sha512-3KLq3pXMS0Y4IELV045fTxqz04Nk9Ms7yfBBHum3yxsTR4XNn+ZCaUbf/mWitgYDAhsplQ0B1G4S5D345lMO3A==
|
||||
|
||||
unicode-canonical-property-names-ecmascript@^1.0.4:
|
||||
version "1.0.4"
|
||||
resolved "https://registry.yarnpkg.com/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz#2619800c4c825800efdd8343af7dd9933cbe2818"
|
||||
@ -9919,11 +10029,16 @@ write-file-atomic@^3.0.0:
|
||||
signal-exit "^3.0.2"
|
||||
typedarray-to-buffer "^3.1.5"
|
||||
|
||||
ws@^7.4.4, ws@^7.4.5:
|
||||
ws@^7.4.5:
|
||||
version "7.5.3"
|
||||
resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.3.tgz#160835b63c7d97bfab418fc1b8a9fced2ac01a74"
|
||||
integrity sha512-kQ/dHIzuLrS6Je9+uv81ueZomEwH0qVYstcAQ4/Z93K8zeko9gtAbttJWzoC5ukqXY1PpoouV3+VSOqEAFt5wg==
|
||||
|
||||
ws@^8.8.1:
|
||||
version "8.8.1"
|
||||
resolved "https://registry.yarnpkg.com/ws/-/ws-8.8.1.tgz#5dbad0feb7ade8ecc99b830c1d77c913d4955ff0"
|
||||
integrity sha512-bGy2JzvzkPowEJV++hF07hAD6niYSr0JzBNo/J29WsB57A2r7Wlc1UFcTR9IzrPvuNVO4B8LGqF8qcpsVOhJCA==
|
||||
|
||||
xml-name-validator@^3.0.0:
|
||||
version "3.0.0"
|
||||
resolved "https://registry.yarnpkg.com/xml-name-validator/-/xml-name-validator-3.0.0.tgz#6ae73e06de4d8c6e47f9fb181f78d648ad457c6a"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user