Skip to content

Commit

Permalink
refactor(log): prepare for noUncheckedIndexedAccess (#4042)
Browse files Browse the repository at this point in the history
  • Loading branch information
syhol committed Dec 30, 2023
1 parent c3da971 commit 756ddf3
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions log/mod.ts
Original file line number Diff line number Diff line change
Expand Up @@ -565,8 +565,7 @@ export function setup(config: LogConfig) {
// setup handlers
const handlers = state.config.handlers || {};

for (const handlerName in handlers) {
const handler = handlers[handlerName];
for (const [handlerName, handler] of Object.entries(handlers)) {
handler.setup();
state.handlers.set(handlerName, handler);
}
Expand All @@ -576,8 +575,7 @@ export function setup(config: LogConfig) {

// setup loggers
const loggers = state.config.loggers || {};
for (const loggerName in loggers) {
const loggerConfig = loggers[loggerName];
for (const [loggerName, loggerConfig] of Object.entries(loggers)) {
const handlerNames = loggerConfig.handlers || [];
const handlers: BaseHandler[] = [];

Expand Down

0 comments on commit 756ddf3

Please sign in to comment.