forked from Icycoide/searxng
[fix] issues reported by pylint-3.2.2
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
This commit is contained in:
parent
e03c7e4dcd
commit
c19bffde4d
3 changed files with 19 additions and 6 deletions
|
@ -17,6 +17,8 @@ Usage in a Flask app route:
|
|||
|
||||
"""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
__all__ = ['InfoPage', 'InfoPageSet']
|
||||
|
||||
import os
|
||||
|
@ -37,6 +39,16 @@ from ..locales import LOCALE_NAMES
|
|||
|
||||
logger = logging.getLogger('searx.infopage')
|
||||
_INFO_FOLDER = os.path.abspath(os.path.dirname(__file__))
|
||||
INFO_PAGES: 'InfoPageSet'
|
||||
|
||||
|
||||
def __getattr__(name):
|
||||
if name == 'INFO_PAGES':
|
||||
global INFO_PAGES # pylint: disable=global-statement
|
||||
INFO_PAGES = InfoPageSet()
|
||||
return INFO_PAGES
|
||||
|
||||
raise AttributeError(f"module {__name__!r} has no attribute {name!r}")
|
||||
|
||||
|
||||
class InfoPage:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue