Import the entire post_init.py file removing the need to seprate init_ prefixed functions
This commit is contained in:
@@ -5,7 +5,7 @@ import tempfile
|
||||
from .utils import validate_path
|
||||
import common.settings as common_settings
|
||||
|
||||
from .settings import TEMPORARY_DIRECTORY
|
||||
|
||||
def init_validate_temp_path():
|
||||
if (validate_path(common_settings.TEMPORARY_DIRECTORY) == False) or (not common_settings.TEMPORARY_DIRECTORY):
|
||||
setattr(common_settings, 'TEMPORARY_DIRECTORY', tempfile.mkdtemp())
|
||||
if (validate_path(getattr(common_settings, 'TEMPORARY_DIRECTORY')) == False) or (not getattr(common_settings, 'TEMPORARY_DIRECTORY')):
|
||||
setattr(common_settings, 'TEMPORARY_DIRECTORY', tempfile.mkdtemp())
|
||||
|
||||
Reference in New Issue
Block a user