Merge pull request #5 from nbitzz:1.3.1

1.3.1
This commit is contained in:
split / May 2023-08-28 09:28:26 -07:00 committed by GitHub
commit 14576c9ed4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View file

@ -118,7 +118,7 @@ app.get("/download/:fileId",(req,res) => {
) )
) )
+ ( + (
fileOwner?.embed?.largeImage && file.visibility!="anonymous" fileOwner?.embed?.largeImage && file.visibility!="anonymous" && file.mime.startsWith("image/")
? `<meta name="twitter:card" content="summary_large_image">` ? `<meta name="twitter:card" content="summary_large_image">`
: "" : ""
) )

View file

@ -166,7 +166,7 @@ authRoutes.post("/embedcolor", requiresAccount, parser, (req,res) => {
if ( if (
!req.body.color !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.toLowerCase())
&& req.body.color.length == 6 && req.body.color.length == 6
) { ) {