Skip to content
This repository has been archived by the owner on Jan 28, 2024. It is now read-only.

How to logger

Elias Schaut edited this page Nov 28, 2021 · 1 revision

The logger helps logging text in console or log_file.
See also: https://github.com/winstonjs/winston (library of used logger)

There are multiple ways to access the logger:

  • message.client.logger.log("<class>", "<log_message>"), if you have the Discord Message attribute
  • client.logger.log("<class>", "<log_message>"), if you have the Discord Client attribute
  • require("<path-to-logger>").log("<class>", "<log_message>")

<class> stands for the type of message.
Default availible classes: ready, debug, warn, error
More classes are addable via the file!

Clone this wiki locally