mirror of
https://github.com/simon987/hexlib.git
synced 2025-04-04 02:12:59 +00:00
Null check on logger
This commit is contained in:
parent
408735a926
commit
18ba0024ea
@ -188,7 +188,8 @@ class Web:
|
||||
self._post = post
|
||||
|
||||
def _error_callback(self, e):
|
||||
self._logger.critical(f"{self._format_url(*self._current_req)}: {e}")
|
||||
if self._logger:
|
||||
self._logger.critical(f"{self._format_url(*self._current_req)}: {e}")
|
||||
|
||||
def _format_url(self, method, url, kwargs, r=None):
|
||||
if "params" in kwargs and kwargs["params"]:
|
||||
|
Loading…
x
Reference in New Issue
Block a user