mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-07-16 02:02:53 -07:00
Refactor module_root -> module_path
This commit is contained in:
parent
aea6e12639
commit
9d0097fa68
3 changed files with 4 additions and 4 deletions
|
@ -23,7 +23,7 @@ except ImportError:
|
|||
if sys.platform == 'win32':
|
||||
sys.ext('Please install pywin32')
|
||||
|
||||
PROGRAM_DIR = libs.util.module_root()
|
||||
PROGRAM_DIR = libs.util.module_path()
|
||||
|
||||
# init preliminaries
|
||||
SYS_ARGV = sys.argv[1:]
|
||||
|
|
|
@ -4,7 +4,7 @@ import sys
|
|||
|
||||
import libs.util
|
||||
|
||||
ROOT_DIR = libs.util.module_root()
|
||||
ROOT_DIR = libs.util.module_path()
|
||||
LIB_DIR = os.path.join(ROOT_DIR, 'libs')
|
||||
|
||||
COMMON = 'common'
|
||||
|
|
|
@ -4,12 +4,12 @@ import sys
|
|||
import os
|
||||
|
||||
__all__ = [
|
||||
'module_root',
|
||||
'module_path',
|
||||
'add_path',
|
||||
]
|
||||
|
||||
|
||||
def module_root(module=__file__):
|
||||
def module_path(module=__file__):
|
||||
try:
|
||||
path = module.__file__
|
||||
except AttributeError:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue