Skip to content

Commit

Permalink
Merge pull request #23 from AthennaIO/develop
Browse files Browse the repository at this point in the history
Update logger provider and package.json
  • Loading branch information
jlenon7 authored May 6, 2022
2 parents a3a673d + d449024 commit d8e6189
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 20 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Template 📔
# Logger 🔍

> Template for new projects
> The Athenna logging solution. Log in stdout, files and buckets.
[![GitHub followers](https://img.shields.io/github/followers/athennaio.svg?style=social&label=Follow&maxAge=2592000)](https://github.com/athennaio?tab=followers)
[![GitHub stars](https://img.shields.io/github/stars/AthennaIO/Logger.svg?style=social&label=Star&maxAge=2592000)](https://github.com/AthennaIO/Logger/stargazers/)
Expand Down
19 changes: 16 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,26 @@
{
"name": "@athenna/logger",
"version": "1.2.1",
"description": "Template for new projects.",
"version": "1.2.2",
"description": "The Athenna logging solution. Log in stdout, files and buckets.",
"license": "MIT",
"author": "João Lenon <lenon@athenna.io>",
"bugs": "https://github.com/AthennaIO/Logger/issues",
"repository": "https://github.com/AthennaIO/Logger.git",
"homepage": "https://github.com/AthennaIO/Logger#readme",
"keywords": [],
"keywords": [
"slack",
"discord",
"telegram",
"console",
"debug",
"pino",
"buckets",
"logger",
"drivers",
"formatters",
"athenna",
"esm"
],
"scripts": {
"lint:fix": "eslint \"{src,tests}/**/*.js\" --fix",
"test": "npm run --silent lint:fix && node ./tests/index.js",
Expand Down
4 changes: 2 additions & 2 deletions src/Providers/LoggerProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ export class LoggerProvider extends ServiceProvider {
/**
* Register any application services.
*
* @return void
* @return {void}
*/
register() {
this.container.bind('Athenna/Core/Logger', Logger)
this.container.bind('Athenna/Core/Logger', Logger, false)
}
}
5 changes: 0 additions & 5 deletions src/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
import { Facade } from '@athenna/ioc'

/**
* Log facade.
*
* @type {Facade & import('../index').Logger}
*/
export const Log: Facade & Logger

export class ColorHelper {
Expand Down
8 changes: 0 additions & 8 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,6 @@ export class Logger {
*/
#drivers = []

/**
* The log channel selected with driver and formatter configurations.
*
* @type {string[]}
*/
#channelNames = []

/**
* Creates a new instance of Logger.
*
Expand Down Expand Up @@ -162,7 +155,6 @@ export class Logger {
*/
channel(...channels) {
this.#drivers = []
this.#channelNames = channels

channels.forEach(channel => {
this.#drivers.push(DriverFactory.fabricate(channel, this.#runtimeConfig))
Expand Down

0 comments on commit d8e6189

Please sign in to comment.