forked from indymedia/epicyon
Remove formatting from youtube replacement domain
parent
041f6b8a63
commit
3d3bcda6db
11
daemon.py
11
daemon.py
|
@ -6311,11 +6311,14 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
if fields.get('ytdomain'):
|
||||
currYTDomain = self.server.YTReplacementDomain
|
||||
if fields['ytdomain'] != currYTDomain:
|
||||
newYTDomain = fields['ytdomain']
|
||||
if '://' in newYTDomain:
|
||||
newYTDomain = newYTDomain.split('://')[1]
|
||||
if '/' in newYTDomain:
|
||||
newYTDomain = newYTDomain.split('/')[0]
|
||||
setConfigParam(self.server.baseDir,
|
||||
'youtubedomain',
|
||||
fields['ytdomain'])
|
||||
self.server.YTReplacementDomain = \
|
||||
fields['ytdomain']
|
||||
'youtubedomain', newYTDomain)
|
||||
self.server.YTReplacementDomain = newYTDomain
|
||||
|
||||
currInstanceDescriptionShort = \
|
||||
getConfigParam(self.server.baseDir,
|
||||
|
|
|
@ -1796,6 +1796,10 @@ if not registration:
|
|||
|
||||
YTDomain = getConfigParam(baseDir, 'youtubedomain')
|
||||
if YTDomain:
|
||||
if '://' in YTDomain:
|
||||
YTDomain = YTDomain.split('://')[1]
|
||||
if '/' in YTDomain:
|
||||
YTDomain = YTDomain.split('/')[0]
|
||||
args.YTReplacementDomain = YTDomain
|
||||
|
||||
if setTheme(baseDir, themeName):
|
||||
|
|
Loading…
Reference in New Issue