forked from indymedia/epicyon
Revert
parent
410e68f048
commit
ac60b52042
15
daemon.py
15
daemon.py
|
@ -3412,21 +3412,6 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
setTheme(baseDir,
|
setTheme(baseDir,
|
||||||
fields['themeDropdown'],
|
fields['themeDropdown'],
|
||||||
domain)
|
domain)
|
||||||
self.server.blogsInstance = \
|
|
||||||
getConfigParam(baseDir,
|
|
||||||
"blogsInstance")
|
|
||||||
fields['blogsInstance'] = \
|
|
||||||
self.server.blogsInstance
|
|
||||||
self.server.mediaInstance = \
|
|
||||||
getConfigParam(baseDir,
|
|
||||||
"mediaInstance")
|
|
||||||
fields['mediaInstance'] = \
|
|
||||||
self.server.mediaInstance
|
|
||||||
self.server.newsInstance = \
|
|
||||||
getConfigParam(baseDir,
|
|
||||||
"newsInstance")
|
|
||||||
fields['newsInstance'] = \
|
|
||||||
self.server.newsInstance
|
|
||||||
|
|
||||||
# change email address
|
# change email address
|
||||||
currentEmailAddress = getEmailAddress(actorJson)
|
currentEmailAddress = getEmailAddress(actorJson)
|
||||||
|
|
24
theme.py
24
theme.py
|
@ -40,28 +40,6 @@ def setThemeInConfig(baseDir: str, name: str) -> bool:
|
||||||
return saveJson(configJson, configFilename)
|
return saveJson(configJson, configFilename)
|
||||||
|
|
||||||
|
|
||||||
def setInstanceTypeInConfig(baseDir: str, name: str) -> bool:
|
|
||||||
configFilename = baseDir + '/config.json'
|
|
||||||
if not os.path.isfile(configFilename):
|
|
||||||
return False
|
|
||||||
configJson = loadJson(configFilename, 0)
|
|
||||||
if not configJson:
|
|
||||||
return False
|
|
||||||
|
|
||||||
configJson['newsInstance'] = False
|
|
||||||
configJson['mediaInstance'] = False
|
|
||||||
configJson['blogsInstance'] = False
|
|
||||||
|
|
||||||
if 'news' in name:
|
|
||||||
configJson['newsInstance'] = True
|
|
||||||
if 'media' in name:
|
|
||||||
configJson['mediaInstance'] = True
|
|
||||||
if 'blog' in name:
|
|
||||||
configJson['blogsInstance'] = True
|
|
||||||
|
|
||||||
return saveJson(configJson, configFilename)
|
|
||||||
|
|
||||||
|
|
||||||
def getTheme(baseDir: str) -> str:
|
def getTheme(baseDir: str) -> str:
|
||||||
configFilename = baseDir + '/config.json'
|
configFilename = baseDir + '/config.json'
|
||||||
if os.path.isfile(configFilename):
|
if os.path.isfile(configFilename):
|
||||||
|
@ -337,7 +315,6 @@ def setThemeIndymedia(baseDir: str):
|
||||||
"login-button-fg-color": "white"
|
"login-button-fg-color": "white"
|
||||||
}
|
}
|
||||||
setThemeFromDict(baseDir, name, themeParams, bgParams)
|
setThemeFromDict(baseDir, name, themeParams, bgParams)
|
||||||
setInstanceTypeInConfig(baseDir, 'news')
|
|
||||||
|
|
||||||
|
|
||||||
def setThemeBlue(baseDir: str):
|
def setThemeBlue(baseDir: str):
|
||||||
|
@ -1034,7 +1011,6 @@ def setThemeImages(baseDir: str, name: str) -> None:
|
||||||
def setTheme(baseDir: str, name: str, domain: str) -> bool:
|
def setTheme(baseDir: str, name: str, domain: str) -> bool:
|
||||||
result = False
|
result = False
|
||||||
|
|
||||||
setInstanceTypeInConfig(baseDir, 'none')
|
|
||||||
prevThemeName = getTheme(baseDir)
|
prevThemeName = getTheme(baseDir)
|
||||||
|
|
||||||
themes = getThemesList()
|
themes = getThemesList()
|
||||||
|
|
Loading…
Reference in New Issue