forked from indymedia/epicyon
Less indentation
parent
3ee24118c2
commit
67b024e128
|
@ -314,44 +314,46 @@ def getEditIconHtml(baseDir: str, nickname: str, domainFull: str,
|
||||||
|
|
||||||
postId = postJsonObject['object']['id']
|
postId = postJsonObject['object']['id']
|
||||||
|
|
||||||
if '/statuses/' in postId:
|
if '/statuses/' not in postId:
|
||||||
if isBlogPost(postJsonObject):
|
return editStr
|
||||||
editBlogPostStr = translate['Edit blog post']
|
|
||||||
if not isNewsPost(postJsonObject):
|
if isBlogPost(postJsonObject):
|
||||||
editStr += \
|
editBlogPostStr = translate['Edit blog post']
|
||||||
' ' + \
|
if not isNewsPost(postJsonObject):
|
||||||
'<a class="imageAnchor" href="/users/' + \
|
|
||||||
nickname + \
|
|
||||||
'/tlblogs?editblogpost=' + \
|
|
||||||
postId.split('/statuses/')[1] + \
|
|
||||||
'?actor=' + actorNickname + \
|
|
||||||
'" title="' + editBlogPostStr + '">' + \
|
|
||||||
'<img loading="lazy" title="' + \
|
|
||||||
editBlogPostStr + '" alt="' + editBlogPostStr + \
|
|
||||||
' |" src="/' + iconsPath + '/edit.png"/></a>\n'
|
|
||||||
else:
|
|
||||||
editStr += \
|
|
||||||
' ' + \
|
|
||||||
'<a class="imageAnchor" href="/users/' + \
|
|
||||||
nickname + '/editnewspost=' + \
|
|
||||||
postId.split('/statuses/')[1] + \
|
|
||||||
'?actor=' + actorNickname + \
|
|
||||||
'" title="' + editBlogPostStr + '">' + \
|
|
||||||
'<img loading="lazy" title="' + \
|
|
||||||
editBlogPostStr + '" alt="' + editBlogPostStr + \
|
|
||||||
' |" src="/' + iconsPath + '/edit.png"/></a>\n'
|
|
||||||
elif isEvent:
|
|
||||||
editEventStr = translate['Edit event']
|
|
||||||
editStr += \
|
editStr += \
|
||||||
' ' + \
|
' ' + \
|
||||||
'<a class="imageAnchor" href="/users/' + nickname + \
|
'<a class="imageAnchor" href="/users/' + \
|
||||||
'/tlblogs?editeventpost=' + \
|
nickname + \
|
||||||
|
'/tlblogs?editblogpost=' + \
|
||||||
postId.split('/statuses/')[1] + \
|
postId.split('/statuses/')[1] + \
|
||||||
'?actor=' + actorNickname + \
|
'?actor=' + actorNickname + \
|
||||||
'" title="' + editEventStr + '">' + \
|
'" title="' + editBlogPostStr + '">' + \
|
||||||
'<img loading="lazy" title="' + \
|
'<img loading="lazy" title="' + \
|
||||||
editEventStr + '" alt="' + editEventStr + \
|
editBlogPostStr + '" alt="' + editBlogPostStr + \
|
||||||
' |" src="/' + iconsPath + '/edit.png"/></a>\n'
|
' |" src="/' + iconsPath + '/edit.png"/></a>\n'
|
||||||
|
else:
|
||||||
|
editStr += \
|
||||||
|
' ' + \
|
||||||
|
'<a class="imageAnchor" href="/users/' + \
|
||||||
|
nickname + '/editnewspost=' + \
|
||||||
|
postId.split('/statuses/')[1] + \
|
||||||
|
'?actor=' + actorNickname + \
|
||||||
|
'" title="' + editBlogPostStr + '">' + \
|
||||||
|
'<img loading="lazy" title="' + \
|
||||||
|
editBlogPostStr + '" alt="' + editBlogPostStr + \
|
||||||
|
' |" src="/' + iconsPath + '/edit.png"/></a>\n'
|
||||||
|
elif isEvent:
|
||||||
|
editEventStr = translate['Edit event']
|
||||||
|
editStr += \
|
||||||
|
' ' + \
|
||||||
|
'<a class="imageAnchor" href="/users/' + nickname + \
|
||||||
|
'/tlblogs?editeventpost=' + \
|
||||||
|
postId.split('/statuses/')[1] + \
|
||||||
|
'?actor=' + actorNickname + \
|
||||||
|
'" title="' + editEventStr + '">' + \
|
||||||
|
'<img loading="lazy" title="' + \
|
||||||
|
editEventStr + '" alt="' + editEventStr + \
|
||||||
|
' |" src="/' + iconsPath + '/edit.png"/></a>\n'
|
||||||
return editStr
|
return editStr
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue