Skip to content

Commit

Permalink
add logging file with Pino
Browse files Browse the repository at this point in the history
  • Loading branch information
pH-7 committed Jun 16, 2024
1 parent 205cc86 commit c1cd634
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion server/fetchSearXNG.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export async function fetchSearXNG(query: string, limit?: number) {

return searchResults;
} catch (e) {
console.error(e);
logger.error(e);
return [];
}
}
5 changes: 5 additions & 0 deletions server/logger.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import pino from "pino";

const logger = pino();

export { logger };

0 comments on commit c1cd634

Please sign in to comment.