mirror of
https://github.com/gitleaks/gitleaks.git
synced 2026-11-28 20:24:22 +01:00
* silence warning about unchecked errors * go-fmt change to add newline * Zerolog requires you to always call .Msg() When logging with zerolog, you need to always end with .Msg(), even if you just pass an empty string. If you read the README on https://github.com/rs/zerolog, they write: > It is very important to note that when using the zerolog > chaining API, as shown above (log.Info().Msg("hello world"), the > chain must have either the Msg or Msgf method call. If you > forget to add either of these, the log will not occur and there > is no compile time error to alert you of this. * Create empty slice without literal * Fix variable / package name collision with literal instead of having a variable named "config", which collides with the package name "config", just pass a literal config.Config{} struct to the function * Replace call to deprecated ioutil.ReadAll() Use io.ReadAll() instead * Check error when closing jsonFile Make it a warning and log error