@sapphire/framework
Version:
Discord bot framework built for advanced and amazing bots.
1 lines • 771 B
Source Map (JSON)
{"version":3,"file":"required.cjs","names":[],"sources":["../../../../../../../src/lib/utils/application-commands/compute-differences/option/required.ts"],"sourcesContent":["import type { CommandDifference } from '../_shared';\n\nexport function* checkOptionRequired({\n\toldRequired,\n\tnewRequired,\n\tkey\n}: {\n\toldRequired?: boolean;\n\tnewRequired?: boolean;\n\tkey: string;\n}): Generator<CommandDifference> {\n\tif ((oldRequired ?? false) !== (newRequired ?? false)) {\n\t\tyield {\n\t\t\tkey,\n\t\t\toriginal: String(oldRequired ?? false),\n\t\t\texpected: String(newRequired ?? false)\n\t\t};\n\t}\n}\n"],"mappings":";;;AAEA,UAAiB,oBAAoB,EACpC,aACA,aACA,OAKgC;AAChC,MAAK,eAAe,YAAY,eAAe,OAC9C,OAAM;EACL;EACA,UAAU,OAAO,eAAe,MAAM;EACtC,UAAU,OAAO,eAAe,MAAM;EACtC"}