From 5be51ddb7ea22c533f0fad1c50fe8cb862fbaf2c Mon Sep 17 00:00:00 2001 From: Lee Hanken Date: Sat, 5 Nov 2022 02:49:07 +0000 Subject: [PATCH] refetch stackoverflow rather than parsing supplied url --- index.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/index.js b/index.js index fa0174b..ea4c8ef 100755 --- a/index.js +++ b/index.js @@ -68,6 +68,10 @@ app.post('/', function(req, res) { if (links) { ignore_links = (links === 'false'); } + if (url && url.startsWith('https://stackoverflow.com/')) { + read_url(url, res, inline_title, ignore_links); + return; + } if (!html) { res.status(400).send("Please provide a POST parameter called html"); } else {