From 5676d356810891d53781775ad1426d7b7128d8d0 Mon Sep 17 00:00:00 2001 From: cloudwithax Date: Sun, 12 Mar 2023 22:51:36 -0400 Subject: [PATCH] make loglevel enum use IntEnum --- pomice/enums.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pomice/enums.py b/pomice/enums.py index 65148a8..6974120 100644 --- a/pomice/enums.py +++ b/pomice/enums.py @@ -1,5 +1,6 @@ import re from enum import Enum +from enum import IntEnum __all__ = ( "SearchType", @@ -247,7 +248,7 @@ class URLRegex: BASE_URL = re.compile(r"https?://(?:www\.)?.+") -class LogLevel(Enum): +class LogLevel(IntEnum): """ The enum for specifying the logging level within Pomice. This class serves as shorthand for logging. @@ -272,6 +273,3 @@ class LogLevel(Enum): WARN = 30 ERROR = 40 CRITICAL = 50 - - def __str__(self) -> str: - return self.value