Better test for news avatar

main
Bob Mottram 2020-10-15 19:21:05 +01:00
parent 326e50ef0e
commit d096b04c04
1 changed files with 2 additions and 3 deletions

View File

@ -1025,9 +1025,8 @@ def setNewsAvatar(baseDir: str, name: str,
"""Sets the avatar for the news account
"""
nickname = 'news'
if name != 'default':
newFilename = baseDir + '/img/icons/' + name + '/avatar_news.png'
else:
newFilename = baseDir + '/img/icons/' + name + '/avatar_news.png'
if not os.path.isfile(newFilename):
newFilename = baseDir + '/img/icons/avatar_news.png'
if not os.path.isfile(newFilename):
return