From a6fc3aec0792d5427bb30fa198eac316206b50cf Mon Sep 17 00:00:00 2001 From: Alfreedom Date: Tue, 5 Sep 2023 12:44:00 +0200 Subject: [PATCH] Include missing file --- lib/apis/utils/log_level.dart | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 lib/apis/utils/log_level.dart diff --git a/lib/apis/utils/log_level.dart b/lib/apis/utils/log_level.dart new file mode 100644 index 00000000..617c83be --- /dev/null +++ b/lib/apis/utils/log_level.dart @@ -0,0 +1,30 @@ +import 'package:logger/logger.dart'; + +enum LogLevel { + verbose, + debug, + info, + warning, + error, + wtf, + nothing; + + Level toLevel() { + switch (this) { + case LogLevel.verbose: + return Level.verbose; + case LogLevel.debug: + return Level.debug; + case LogLevel.info: + return Level.info; + case LogLevel.warning: + return Level.warning; + case LogLevel.error: + return Level.error; + case LogLevel.wtf: + return Level.wtf; + default: + return Level.nothing; + } + } +}