mirror of
https://github.com/deadc0de6/dotdrop.git
synced 2026-02-12 00:09:02 +00:00
cleaning
This commit is contained in:
@@ -39,15 +39,12 @@ class Logger:
|
|||||||
ce = self._color(self.RESET)
|
ce = self._color(self.RESET)
|
||||||
sys.stderr.write('{}{}{}'.format(cs, string, ce))
|
sys.stderr.write('{}{}{}'.format(cs, string, ce))
|
||||||
|
|
||||||
def err(self, string, end='\n', *, throw=None):
|
def err(self, string, end='\n'):
|
||||||
cs = self._color(self.RED)
|
cs = self._color(self.RED)
|
||||||
ce = self._color(self.RESET)
|
ce = self._color(self.RESET)
|
||||||
msg = '{} {}'.format(string, end)
|
msg = '{} {}'.format(string, end)
|
||||||
sys.stderr.write('{}[ERR] {}{}'.format(cs, msg, ce))
|
sys.stderr.write('{}[ERR] {}{}'.format(cs, msg, ce))
|
||||||
|
|
||||||
if throw is not None:
|
|
||||||
raise throw(msg)
|
|
||||||
|
|
||||||
def warn(self, string, end='\n'):
|
def warn(self, string, end='\n'):
|
||||||
cs = self._color(self.YELLOW)
|
cs = self._color(self.YELLOW)
|
||||||
ce = self._color(self.RESET)
|
ce = self._color(self.RESET)
|
||||||
|
|||||||
Reference in New Issue
Block a user