From 5b9d6ad35b8612adc9bff17d94f0b5097d0389e0 Mon Sep 17 00:00:00 2001 From: devo1ution Date: Wed, 28 Feb 2024 15:55:48 -0800 Subject: [PATCH] remove extra logging --- usaco_util.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/usaco_util.ts b/usaco_util.ts index c20e9a5..2445366 100644 --- a/usaco_util.ts +++ b/usaco_util.ts @@ -6,7 +6,6 @@ const problems = require('./problems.json') as { [key: string]: ProblemData }; let report = 'added problems:\n```\n'; async function addProblem(id: number) { - console.log('Adding problem ', id); try { const url = `https://usaco.org/index.php?page=viewproblem2&cpid=${id}`; const response = await (await fetch(url)).text(); @@ -59,7 +58,7 @@ async function addProblem(id: number) { ); return true; } catch (error) { - console.log(error); + if (!(error instanceof TypeError)) console.log(error); return false; } }