make tags required lol

This commit is contained in:
Ashley Graves 2024-10-10 16:24:12 +02:00
parent 67bc03433e
commit 3ff8ebadfd
3 changed files with 8 additions and 10 deletions

View file

@ -8,7 +8,7 @@
"author": "", "author": "",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@himeka/booru": "github:asadahimeka/booru-search", "@himeka/booru": "^2.7.7",
"@imgproxy/imgproxy-node": "^1.0.6", "@imgproxy/imgproxy-node": "^1.0.6",
"discord.js": "^14.16.3", "discord.js": "^14.16.3",
"dotenv": "^16.4.5", "dotenv": "^16.4.5",

View file

@ -9,8 +9,8 @@ importers:
.: .:
dependencies: dependencies:
'@himeka/booru': '@himeka/booru':
specifier: github:asadahimeka/booru-search specifier: ^2.7.7
version: https://codeload.github.com/asadahimeka/booru-search/tar.gz/9599c1c7e2ab8467ac6b0ce7d5300c621e4b00b9 version: 2.7.7
'@imgproxy/imgproxy-node': '@imgproxy/imgproxy-node':
specifier: ^1.0.6 specifier: ^1.0.6
version: 1.0.6 version: 1.0.6
@ -60,9 +60,8 @@ packages:
resolution: {integrity: sha512-PZ+vLpxGCRtmr2RMkqh8Zp+BenUaJqlS6xhgWKEZcgC/vfHLEzpHtKkB0sl3nZWpwtcKk6YWy+pU3okL2I97FA==} resolution: {integrity: sha512-PZ+vLpxGCRtmr2RMkqh8Zp+BenUaJqlS6xhgWKEZcgC/vfHLEzpHtKkB0sl3nZWpwtcKk6YWy+pU3okL2I97FA==}
engines: {node: '>=16.11.0'} engines: {node: '>=16.11.0'}
'@himeka/booru@https://codeload.github.com/asadahimeka/booru-search/tar.gz/9599c1c7e2ab8467ac6b0ce7d5300c621e4b00b9': '@himeka/booru@2.7.7':
resolution: {tarball: https://codeload.github.com/asadahimeka/booru-search/tar.gz/9599c1c7e2ab8467ac6b0ce7d5300c621e4b00b9} resolution: {integrity: sha512-8svZVugOp7eaIU6YN6+Fol+thHv++wrkSD0aOKCp+MKX4T7L9hjQ8c+YcKl00Ty6PBgNTAM9mikbVQ9xYJrT8w==}
version: 2.7.7
engines: {node: '>=10.0.0'} engines: {node: '>=10.0.0'}
'@imgproxy/imgproxy-js-core@1.0.8': '@imgproxy/imgproxy-js-core@1.0.8':
@ -303,7 +302,7 @@ snapshots:
- bufferutil - bufferutil
- utf-8-validate - utf-8-validate
'@himeka/booru@https://codeload.github.com/asadahimeka/booru-search/tar.gz/9599c1c7e2ab8467ac6b0ce7d5300c621e4b00b9': '@himeka/booru@2.7.7':
dependencies: dependencies:
fast-xml-parser: 4.4.0 fast-xml-parser: 4.4.0
isomorphic-unfetch: 3.1.0 isomorphic-unfetch: 3.1.0

View file

@ -4,7 +4,7 @@ const { stringify } = require("node:querystring");
const { readFileSync } = require("node:fs"); const { readFileSync } = require("node:fs");
const { decode } = require("html-entities"); const { decode } = require("html-entities");
const { extname } = require("node:path"); const { extname } = require("node:path");
const Booru = require('@himeka/booru'); const Booru = require("@himeka/booru");
const boorus = []; const boorus = [];
for (const site of Object.keys(Booru.sites)) { for (const site of Object.keys(Booru.sites)) {
@ -22,13 +22,12 @@ const data = new SlashCommandBuilder()
.addStringOption(builder => .addStringOption(builder =>
builder // builder //
.setName("tags") .setName("tags")
.setRequired(false) .setRequired(true)
.setDescription("Tags to search for") .setDescription("Tags to search for")
) )
.addStringOption(builder => .addStringOption(builder =>
builder // builder //
.setName("booru") .setName("booru")
.setRequired(false)
.setDescription("Booru board to search (default: safebooru.org)") .setDescription("Booru board to search (default: safebooru.org)")
.addChoices(boorus) .addChoices(boorus)
) )