mirror of https://gitlab.com/bashrc2/epicyon
Set avatar image media types
parent
0a9fd492d3
commit
0c9d753c22
14
daemon.py
14
daemon.py
|
@ -3778,6 +3778,13 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
actorJson['icon']['url'] = \
|
||||
actorJson['icon']['url'].replace(srchStr,
|
||||
repStr)
|
||||
if '.' in actorJson['icon']['url']:
|
||||
imgExt = \
|
||||
actorJson['icon']['url'].split('.')[-1]
|
||||
if imgExt == 'jpg':
|
||||
imgExt = 'jpeg'
|
||||
actorJson['icon']['mediaType'] = \
|
||||
'image/' + imgExt
|
||||
elif mType == 'image':
|
||||
lastPartOfUrl = \
|
||||
actorJson['image']['url'].split('/')[-1]
|
||||
|
@ -3785,6 +3792,13 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
actorJson['image']['url'] = \
|
||||
actorJson['image']['url'].replace(srchStr,
|
||||
repStr)
|
||||
if '.' in actorJson['image']['url']:
|
||||
imgExt = \
|
||||
actorJson['image']['url'].split('.')[-1]
|
||||
if imgExt == 'jpg':
|
||||
imgExt = 'jpeg'
|
||||
actorJson['image']['mediaType'] = \
|
||||
'image/' + imgExt
|
||||
|
||||
# set skill levels
|
||||
skillCtr = 1
|
||||
|
|
Loading…
Reference in New Issue