Skip to content
This repository was archived by the owner on May 12, 2021. It is now read-only.

Supports ignorePaths option#1

Open
alexdeia wants to merge 3 commits intokasa-network:masterfrom
alexdeia:master
Open

Supports ignorePaths option#1
alexdeia wants to merge 3 commits intokasa-network:masterfrom
alexdeia:master

Conversation

@alexdeia
Copy link
Copy Markdown

@alexdeia alexdeia commented Jun 3, 2020

A little PR to improve the configuration.

Before these changes, I did something like this

    this.use(async (ctx, next) => {
      if (ctx.url === '/api') {
        await next();
      } else {
        await logging({
          logger,
          overrideSerializers: false
        })(ctx, next);
      }
    });

After I can use this

    this.use(logging({
      logger,
      ignorePaths: ['/api'],
      overrideSerializers: false
    }));

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant