Remove console logs.

This commit is contained in:
Bradley Shellnut 2023-02-17 13:08:12 -08:00
parent decae89479
commit 5701a40d3a
4 changed files with 7 additions and 7 deletions

View file

@ -27,7 +27,7 @@ export async function fetchBandcampAlbums() {
});
const albums: Album[] = data?.collectionItems || [];
console.log(`Albums ${JSON.stringify(albums)}`);
// console.log(`Albums ${JSON.stringify(albums)}`);
if (albums && albums?.length > 0) {
return albums;
@ -35,6 +35,6 @@ export async function fetchBandcampAlbums() {
return [];
}
} catch (error) {
console.log(error);
console.error(error);
}
}

View file

@ -14,7 +14,7 @@
let totalArticles: number;
$: ({ albums, articlesData } = data);
$: ({ articles, totalArticles } = articlesData);
$: console.log(`All data: ${JSON.stringify(articlesData)}`);
// $: console.log(`All data: ${JSON.stringify(articlesData)}`);
const userNames = {
github: 'BradNut',

View file

@ -38,14 +38,14 @@ export async function fetchArticlesApi(
since: `${pageQuery.since}`,
page: `${pageQuery.page}`
});
console.log(`Entries params: ${entriesQueryParams}`);
// console.log(`Entries params: ${entriesQueryParams}`);
if (USE_REDIS_CACHE) {
const cached = await redis.get(entriesQueryParams.toString());
if (cached) {
const response = JSON.parse(cached);
console.log('Cache hit!');
// console.log('Cache hit!');
const ttl = await redis.ttl(entriesQueryParams.toString());
return { ...response, cacheControl: `max-age=${ttl}` };
@ -86,7 +86,7 @@ export async function fetchArticlesApi(
// do {
// nbEntries += entries._embedded.items.length;
console.log(`number of articles fetched: ${_embedded.items.length}`);
// console.log(`number of articles fetched: ${_embedded.items.length}`);
_embedded.items.forEach((article: WallabagArticle) => {
// if (articles?.length === +WALLABAG_MAX_ARTICLES) {
// console.log('Reached 30 articles');

View file

@ -27,7 +27,7 @@ export const GET: RequestHandler = async ({ setHeaders, url }: RequestEvent) =>
}
}
console.log(`API response ${JSON.stringify(response)}`);
// console.log(`API response ${JSON.stringify(response)}`);
return json(response);
}
} catch (e) {