Level.String panics if Level == InvalidLevel
Offen
- Vorherrschende Sprache
- Go
- Sterne
- 1.4k
- Forks
- 110
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
hi,
the method `LeveL.String` panics when `Level==InvalidLevel`.
https://github.com/apex/log/blob/master/levels.go#L44
https://github.com/apex/log/blob/master/levels.go#L17
I suggest to add a statement before the slice access so that this pseudo value does not appear in the `levelNames` / `levelStrings` variables.
It could return an empty string or something like `invalid`
Beitragsleitfaden
Für dieses Repository ist kein Beitragsleitfaden indexiert
Bewertung
Dieses Issue wurde noch nicht bewertet.