Small fixes

This commit is contained in:
May 2023-08-01 17:47:46 +00:00
parent 45da932326
commit 5281021f71
2 changed files with 2 additions and 2 deletions

View file

@ -164,7 +164,7 @@ app.get("/download/:fileId",(req,res) => {
)
+ (
fileOwner?.embed?.largeImage
? `<meta name="twitter:image" content="/assets/reallycoolfish.jpg">`
? `<meta name="twitter:card" content="summary_large_image">`
: ""
)
+ `\n<meta name="theme-color" content="${fileOwner?.embed?.color && (req.headers["user-agent"]||"").includes("Discordbot") ? `#${fileOwner.embed.color}` : "rgb(30, 33, 36)"}">`

View file

@ -175,7 +175,7 @@ authRoutes.post("/embedcolor", parser, (req,res) => {
if (
!req.body.color
|| (req.body.color.toLowerCase().match(/[a-f0-9]/) == req.body.color)
|| (req.body.color.toLowerCase().match(/[a-f0-9]+/) == req.body.color)
&& req.body.color.length == 6
) {