kopia lustrzana https://github.com/OpenDroneMap/WebODM
Get settings.py through django.conf
The previous "from webodm import settings" would get the first settings.py Using django.conf is a better option This is discussed in this Stack Overflow topic: https://stackoverflow.com/questions/19976115/whats-the-difference-between-from-django-conf-import-settings-and-import-set And in the docs: https://docs.djangoproject.com/en/dev/topics/settings/#using-settings-in-python-codepull/712/head
rodzic
66deb3809a
commit
9c61e27082
|
@ -14,7 +14,7 @@ from django.http import HttpResponse
|
|||
|
||||
from app.models import Plugin
|
||||
from app.models import Setting
|
||||
from webodm import settings
|
||||
from django.conf import settings
|
||||
|
||||
logger = logging.getLogger('app.logger')
|
||||
|
||||
|
@ -306,4 +306,4 @@ def versionToInt(version):
|
|||
try:
|
||||
return sum([reduce(lambda mult, ver: mult * ver, i) for i in zip([100000, 100, 1], map(int, version.split(".")))])
|
||||
except:
|
||||
return -1
|
||||
return -1
|
||||
|
|
Ładowanie…
Reference in New Issue