New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fmt/log.Println like logging, Adding more verbosity #280
Conversation
kennedy
commented
Mar 28, 2020
- Increased verbosity:
- Whenever an irc handler triggers
- Whenever an irc event handler has been added. Provides more details into which handlers were added.
- Added log notification when telegram bot has logged in.
Increased verbosity for ircc handler triggers. Logging each event handler as it is added, instead of a general add. Provides more details into which handlers were added. Added log notification when telegram bot has logged inn.
@@ -14,33 +14,33 @@ var ( | |||
|
|||
// DebugLogger provides an interface to call the logging functions | |||
type DebugLogger interface { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Behaves just like fmt.Println()
or log.Println()
for example: logger.LogInfo("random pre-fix string", 10) # random pre-fix string 10
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The use of interface is definitely a good idea. Overall, I think is it a good PR. Before merging, would you add a space before concatenating string on these lines?
c.logger.LogInfo("Adding IRC event handler:", eventType)
tg.logger.LogInfo("Authorized on account",tg.api.Self.UserName)
@10eMyrT Fortunately a space is automatically joined between the interfaces |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
mergeeeed |