Skip to content

Commit

Permalink
- chore(translate.py): remove redundant installation check in Transla…
Browse files Browse the repository at this point in the history
…tor class constructor

- fix(translate.py): add skip_install parameter to Translator class constructor
  • Loading branch information
alan890104 committed Sep 19, 2023
1 parent 65dbcb4 commit 852873f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions decodex/translate/translate.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,8 @@ def __init__(
logger : Logger, optional
Logger to log error messages, default is None
"""
if not skip_install:
self.install()

self.tagger = TaggerFactory.create(tagger) if isinstance(tagger, str) else tagger

Expand All @@ -112,9 +114,6 @@ def __init__(
if logger is None and verbose:
self.logger = Logger(name=self.__class__.__name__)

if not skip_install:
self.install()

def install(self):
from decodex import installer
from decodex import constant
Expand Down

0 comments on commit 852873f

Please sign in to comment.