mirror of https://gitlab.com/bashrc2/epicyon
Maximum likes displayed on posts is configurable
parent
d0c4bc1cfa
commit
af9a6cc6d1
57
daemon.py
57
daemon.py
|
@ -2928,7 +2928,8 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.peertubeInstances,
|
self.server.peertubeInstances,
|
||||||
self.server.allowLocalNetworkAccess,
|
self.server.allowLocalNetworkAccess,
|
||||||
self.server.themeName,
|
self.server.themeName,
|
||||||
self.server.systemLanguage)
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount)
|
||||||
if hashtagStr:
|
if hashtagStr:
|
||||||
msg = hashtagStr.encode('utf-8')
|
msg = hashtagStr.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -2983,7 +2984,8 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.peertubeInstances,
|
self.server.peertubeInstances,
|
||||||
self.server.allowLocalNetworkAccess,
|
self.server.allowLocalNetworkAccess,
|
||||||
self.server.themeName, 'outbox',
|
self.server.themeName, 'outbox',
|
||||||
self.server.systemLanguage)
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount)
|
||||||
if historyStr:
|
if historyStr:
|
||||||
msg = historyStr.encode('utf-8')
|
msg = historyStr.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -3018,7 +3020,8 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.peertubeInstances,
|
self.server.peertubeInstances,
|
||||||
self.server.allowLocalNetworkAccess,
|
self.server.allowLocalNetworkAccess,
|
||||||
self.server.themeName, 'bookmarks',
|
self.server.themeName, 'bookmarks',
|
||||||
self.server.systemLanguage)
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount)
|
||||||
if bookmarksStr:
|
if bookmarksStr:
|
||||||
msg = bookmarksStr.encode('utf-8')
|
msg = bookmarksStr.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -3113,7 +3116,8 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
self.server.themeName,
|
self.server.themeName,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage)
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount)
|
||||||
if profileStr:
|
if profileStr:
|
||||||
msg = profileStr.encode('utf-8')
|
msg = profileStr.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -6347,7 +6351,8 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.peertubeInstances,
|
self.server.peertubeInstances,
|
||||||
self.server.allowLocalNetworkAccess,
|
self.server.allowLocalNetworkAccess,
|
||||||
self.server.themeName,
|
self.server.themeName,
|
||||||
self.server.systemLanguage)
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount)
|
||||||
if hashtagStr:
|
if hashtagStr:
|
||||||
msg = hashtagStr.encode('utf-8')
|
msg = hashtagStr.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -7289,7 +7294,8 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.peertubeInstances,
|
self.server.peertubeInstances,
|
||||||
self.server.allowLocalNetworkAccess,
|
self.server.allowLocalNetworkAccess,
|
||||||
self.server.themeName,
|
self.server.themeName,
|
||||||
self.server.systemLanguage)
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount)
|
||||||
if deleteStr:
|
if deleteStr:
|
||||||
deleteStrLen = len(deleteStr)
|
deleteStrLen = len(deleteStr)
|
||||||
self._set_headers('text/html', deleteStrLen,
|
self._set_headers('text/html', deleteStrLen,
|
||||||
|
@ -7498,7 +7504,8 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
self.server.allowLocalNetworkAccess,
|
self.server.allowLocalNetworkAccess,
|
||||||
self.server.themeName,
|
self.server.themeName,
|
||||||
self.server.systemLanguage)
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
self._set_headers('text/html', msglen,
|
self._set_headers('text/html', msglen,
|
||||||
|
@ -7587,7 +7594,8 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
self.server.allowLocalNetworkAccess,
|
self.server.allowLocalNetworkAccess,
|
||||||
self.server.themeName,
|
self.server.themeName,
|
||||||
self.server.systemLanguage)
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
self._set_headers('text/html', msglen,
|
self._set_headers('text/html', msglen,
|
||||||
|
@ -7687,6 +7695,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.debug,
|
self.server.debug,
|
||||||
accessKeys, city,
|
accessKeys, city,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
self.server.sharedItemsFederatedDomains,
|
self.server.sharedItemsFederatedDomains,
|
||||||
rolesList,
|
rolesList,
|
||||||
None, None)
|
None, None)
|
||||||
|
@ -7790,6 +7799,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.debug,
|
self.server.debug,
|
||||||
accessKeys, city,
|
accessKeys, city,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
sharedItemsFederatedDomains,
|
sharedItemsFederatedDomains,
|
||||||
skills,
|
skills,
|
||||||
None, None)
|
None, None)
|
||||||
|
@ -7925,7 +7935,8 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.peertubeInstances,
|
self.server.peertubeInstances,
|
||||||
self.server.allowLocalNetworkAccess,
|
self.server.allowLocalNetworkAccess,
|
||||||
self.server.themeName,
|
self.server.themeName,
|
||||||
self.server.systemLanguage)
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
self._set_headers('text/html', msglen,
|
self._set_headers('text/html', msglen,
|
||||||
|
@ -8138,6 +8149,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.textModeBanner,
|
self.server.textModeBanner,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
if GETstartTime:
|
if GETstartTime:
|
||||||
self._benchmarkGETtimings(GETstartTime, GETtimings,
|
self._benchmarkGETtimings(GETstartTime, GETtimings,
|
||||||
|
@ -8278,6 +8290,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.textModeBanner,
|
self.server.textModeBanner,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -8411,6 +8424,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.textModeBanner,
|
self.server.textModeBanner,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -8543,6 +8557,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.textModeBanner,
|
self.server.textModeBanner,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
self.server.sharedItemsFederatedDomains)
|
self.server.sharedItemsFederatedDomains)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -8675,6 +8690,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.textModeBanner,
|
self.server.textModeBanner,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
self.server.sharedItemsFederatedDomains)
|
self.server.sharedItemsFederatedDomains)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -8816,6 +8832,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.textModeBanner,
|
self.server.textModeBanner,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
self.server.sharedItemsFederatedDomains)
|
self.server.sharedItemsFederatedDomains)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -8955,6 +8972,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.textModeBanner,
|
self.server.textModeBanner,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -9053,6 +9071,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.textModeBanner,
|
self.server.textModeBanner,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
self.server.sharedItemsFederatedDomains)
|
self.server.sharedItemsFederatedDomains)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -9170,6 +9189,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.textModeBanner,
|
self.server.textModeBanner,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -9299,6 +9319,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.textModeBanner,
|
self.server.textModeBanner,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
self.server.sharedItemsFederatedDomains)
|
self.server.sharedItemsFederatedDomains)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -9418,6 +9439,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.textModeBanner,
|
self.server.textModeBanner,
|
||||||
accessKeys,
|
accessKeys,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
msg = msg.encode('utf-8')
|
msg = msg.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -9535,6 +9557,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.debug,
|
self.server.debug,
|
||||||
accessKeys, city,
|
accessKeys, city,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
self.server.sharedItemsFederatedDomains,
|
self.server.sharedItemsFederatedDomains,
|
||||||
shares,
|
shares,
|
||||||
pageNumber, sharesPerPage)
|
pageNumber, sharesPerPage)
|
||||||
|
@ -9650,6 +9673,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.debug,
|
self.server.debug,
|
||||||
accessKeys, city,
|
accessKeys, city,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
self.server.sharedItemsFederatedDomains,
|
self.server.sharedItemsFederatedDomains,
|
||||||
following,
|
following,
|
||||||
pageNumber,
|
pageNumber,
|
||||||
|
@ -9765,6 +9789,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.debug,
|
self.server.debug,
|
||||||
accessKeys, city,
|
accessKeys, city,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
self.server.sharedItemsFederatedDomains,
|
self.server.sharedItemsFederatedDomains,
|
||||||
followers,
|
followers,
|
||||||
pageNumber,
|
pageNumber,
|
||||||
|
@ -9903,6 +9928,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.debug,
|
self.server.debug,
|
||||||
accessKeys, city,
|
accessKeys, city,
|
||||||
self.server.systemLanguage,
|
self.server.systemLanguage,
|
||||||
|
self.server.maxLikeCount,
|
||||||
self.server.sharedItemsFederatedDomains,
|
self.server.sharedItemsFederatedDomains,
|
||||||
None, None).encode('utf-8')
|
None, None).encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -14993,7 +15019,8 @@ def loadTokens(baseDir: str, tokensDict: {}, tokensLookup: {}) -> None:
|
||||||
break
|
break
|
||||||
|
|
||||||
|
|
||||||
def runDaemon(sharedItemsFederatedDomains: [],
|
def runDaemon(maxLikeCount: int,
|
||||||
|
sharedItemsFederatedDomains: [],
|
||||||
userAgentsBlocked: [],
|
userAgentsBlocked: [],
|
||||||
logLoginFailures: bool,
|
logLoginFailures: bool,
|
||||||
city: str,
|
city: str,
|
||||||
|
@ -15232,6 +15259,13 @@ def runDaemon(sharedItemsFederatedDomains: [],
|
||||||
# for it to be considered dormant?
|
# for it to be considered dormant?
|
||||||
httpd.dormantMonths = dormantMonths
|
httpd.dormantMonths = dormantMonths
|
||||||
|
|
||||||
|
# maximum number of likes to display on a post
|
||||||
|
httpd.maxLikeCount = maxLikeCount
|
||||||
|
if httpd.maxLikeCount < 0:
|
||||||
|
httpd.maxLikeCount = 0
|
||||||
|
elif httpd.maxLikeCount > 99:
|
||||||
|
httpd.maxLikeCount = 99
|
||||||
|
|
||||||
httpd.followingItemsPerPage = 12
|
httpd.followingItemsPerPage = 12
|
||||||
if registration == 'open':
|
if registration == 'open':
|
||||||
httpd.registration = True
|
httpd.registration = True
|
||||||
|
@ -15434,7 +15468,8 @@ def runDaemon(sharedItemsFederatedDomains: [],
|
||||||
httpd.peertubeInstances,
|
httpd.peertubeInstances,
|
||||||
verifyAllSignatures,
|
verifyAllSignatures,
|
||||||
httpd.themeName,
|
httpd.themeName,
|
||||||
httpd.systemLanguage), daemon=True)
|
httpd.systemLanguage,
|
||||||
|
httpd.maxLikeCount), daemon=True)
|
||||||
|
|
||||||
print('Creating scheduled post thread')
|
print('Creating scheduled post thread')
|
||||||
httpd.thrPostSchedule = \
|
httpd.thrPostSchedule = \
|
||||||
|
|
11
epicyon.py
11
epicyon.py
|
@ -449,6 +449,9 @@ parser.add_argument('--minimumvotes', dest='minimumvotes', type=int,
|
||||||
default=1,
|
default=1,
|
||||||
help='Minimum number of votes to remove or add' +
|
help='Minimum number of votes to remove or add' +
|
||||||
' a newswire item')
|
' a newswire item')
|
||||||
|
parser.add_argument('--maxLikeCount', dest='maxLikeCount', type=int,
|
||||||
|
default=10,
|
||||||
|
help='Maximum number of likes displayed on a post')
|
||||||
parser.add_argument('--votingtime', dest='votingtime', type=int,
|
parser.add_argument('--votingtime', dest='votingtime', type=int,
|
||||||
default=1440,
|
default=1440,
|
||||||
help='Time to vote on newswire items in minutes')
|
help='Time to vote on newswire items in minutes')
|
||||||
|
@ -2584,6 +2587,11 @@ sendThreadsTimeoutMins = \
|
||||||
if sendThreadsTimeoutMins is not None:
|
if sendThreadsTimeoutMins is not None:
|
||||||
args.sendThreadsTimeoutMins = int(sendThreadsTimeoutMins)
|
args.sendThreadsTimeoutMins = int(sendThreadsTimeoutMins)
|
||||||
|
|
||||||
|
maxLikeCount = \
|
||||||
|
getConfigParam(baseDir, 'maxLikeCount')
|
||||||
|
if maxLikeCount is not None:
|
||||||
|
args.maxLikeCount = int(maxLikeCount)
|
||||||
|
|
||||||
showPublishAsIcon = \
|
showPublishAsIcon = \
|
||||||
getConfigParam(baseDir, 'showPublishAsIcon')
|
getConfigParam(baseDir, 'showPublishAsIcon')
|
||||||
if showPublishAsIcon is not None:
|
if showPublishAsIcon is not None:
|
||||||
|
@ -2687,7 +2695,8 @@ if args.registration:
|
||||||
print('New registrations closed')
|
print('New registrations closed')
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
runDaemon(sharedItemsFederatedDomains,
|
runDaemon(args.maxLikeCount,
|
||||||
|
sharedItemsFederatedDomains,
|
||||||
userAgentsBlocked,
|
userAgentsBlocked,
|
||||||
args.logLoginFailures,
|
args.logLoginFailures,
|
||||||
args.city,
|
args.city,
|
||||||
|
|
17
inbox.py
17
inbox.py
|
@ -167,7 +167,8 @@ def _inboxStorePostToHtmlCache(recentPostsCache: {}, maxRecentPosts: int,
|
||||||
showPublishedDateOnly: bool,
|
showPublishedDateOnly: bool,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
themeName: str, systemLanguage: str) -> None:
|
themeName: str, systemLanguage: str,
|
||||||
|
maxLikeCount: int) -> None:
|
||||||
"""Converts the json post into html and stores it in a cache
|
"""Converts the json post into html and stores it in a cache
|
||||||
This enables the post to be quickly displayed later
|
This enables the post to be quickly displayed later
|
||||||
"""
|
"""
|
||||||
|
@ -185,7 +186,7 @@ def _inboxStorePostToHtmlCache(recentPostsCache: {}, maxRecentPosts: int,
|
||||||
httpPrefix, __version__, boxname, None,
|
httpPrefix, __version__, boxname, None,
|
||||||
showPublishedDateOnly,
|
showPublishedDateOnly,
|
||||||
peertubeInstances, allowLocalNetworkAccess,
|
peertubeInstances, allowLocalNetworkAccess,
|
||||||
themeName, systemLanguage,
|
themeName, systemLanguage, maxLikeCount,
|
||||||
not isDM(postJsonObject),
|
not isDM(postJsonObject),
|
||||||
True, True, False, True)
|
True, True, False, True)
|
||||||
|
|
||||||
|
@ -2246,7 +2247,8 @@ def _inboxAfterInitial(recentPostsCache: {}, maxRecentPosts: int,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
lastBounceMessage: [],
|
lastBounceMessage: [],
|
||||||
themeName: str, systemLanguage: str) -> bool:
|
themeName: str, systemLanguage: str,
|
||||||
|
maxLikeCount: int) -> bool:
|
||||||
""" Anything which needs to be done after initial checks have passed
|
""" Anything which needs to be done after initial checks have passed
|
||||||
"""
|
"""
|
||||||
actor = keyId
|
actor = keyId
|
||||||
|
@ -2572,7 +2574,8 @@ def _inboxAfterInitial(recentPostsCache: {}, maxRecentPosts: int,
|
||||||
showPublishedDateOnly,
|
showPublishedDateOnly,
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
themeName, systemLanguage)
|
themeName, systemLanguage,
|
||||||
|
maxLikeCount)
|
||||||
if debug:
|
if debug:
|
||||||
timeDiff = \
|
timeDiff = \
|
||||||
str(int((time.time() - htmlCacheStartTime) *
|
str(int((time.time() - htmlCacheStartTime) *
|
||||||
|
@ -2832,7 +2835,8 @@ def runInboxQueue(recentPostsCache: {}, maxRecentPosts: int,
|
||||||
maxFollowers: int, allowLocalNetworkAccess: bool,
|
maxFollowers: int, allowLocalNetworkAccess: bool,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
verifyAllSignatures: bool,
|
verifyAllSignatures: bool,
|
||||||
themeName: str, systemLanguage: str) -> None:
|
themeName: str, systemLanguage: str,
|
||||||
|
maxLikeCount: int) -> None:
|
||||||
"""Processes received items and moves them to the appropriate
|
"""Processes received items and moves them to the appropriate
|
||||||
directories
|
directories
|
||||||
"""
|
"""
|
||||||
|
@ -3220,7 +3224,8 @@ def runInboxQueue(recentPostsCache: {}, maxRecentPosts: int,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
lastBounceMessage,
|
lastBounceMessage,
|
||||||
themeName, systemLanguage)
|
themeName, systemLanguage,
|
||||||
|
maxLikeCount)
|
||||||
if debug:
|
if debug:
|
||||||
pprint(queueJson['post'])
|
pprint(queueJson['post'])
|
||||||
print('Queue: Queue post accepted')
|
print('Queue: Queue post accepted')
|
||||||
|
|
16
tests.py
16
tests.py
|
@ -568,8 +568,10 @@ def createServerAlice(path: str, domain: str, port: int,
|
||||||
city = 'London, England'
|
city = 'London, England'
|
||||||
logLoginFailures = False
|
logLoginFailures = False
|
||||||
userAgentsBlocked = []
|
userAgentsBlocked = []
|
||||||
|
maxLikeCount = 10
|
||||||
print('Server running: Alice')
|
print('Server running: Alice')
|
||||||
runDaemon(sharedItemsFederatedDomains,
|
runDaemon(maxLikeCount,
|
||||||
|
sharedItemsFederatedDomains,
|
||||||
userAgentsBlocked,
|
userAgentsBlocked,
|
||||||
logLoginFailures, city,
|
logLoginFailures, city,
|
||||||
showNodeInfoAccounts,
|
showNodeInfoAccounts,
|
||||||
|
@ -697,8 +699,10 @@ def createServerBob(path: str, domain: str, port: int,
|
||||||
city = 'London, England'
|
city = 'London, England'
|
||||||
logLoginFailures = False
|
logLoginFailures = False
|
||||||
userAgentsBlocked = []
|
userAgentsBlocked = []
|
||||||
|
maxLikeCount = 10
|
||||||
print('Server running: Bob')
|
print('Server running: Bob')
|
||||||
runDaemon(sharedItemsFederatedDomains,
|
runDaemon(maxLikeCount,
|
||||||
|
sharedItemsFederatedDomains,
|
||||||
userAgentsBlocked,
|
userAgentsBlocked,
|
||||||
logLoginFailures, city,
|
logLoginFailures, city,
|
||||||
showNodeInfoAccounts,
|
showNodeInfoAccounts,
|
||||||
|
@ -759,8 +763,10 @@ def createServerEve(path: str, domain: str, port: int, federationList: [],
|
||||||
city = 'London, England'
|
city = 'London, England'
|
||||||
logLoginFailures = False
|
logLoginFailures = False
|
||||||
userAgentsBlocked = []
|
userAgentsBlocked = []
|
||||||
|
maxLikeCount = 10
|
||||||
print('Server running: Eve')
|
print('Server running: Eve')
|
||||||
runDaemon(sharedItemsFederatedDomains,
|
runDaemon(maxLikeCount,
|
||||||
|
sharedItemsFederatedDomains,
|
||||||
userAgentsBlocked,
|
userAgentsBlocked,
|
||||||
logLoginFailures, city,
|
logLoginFailures, city,
|
||||||
showNodeInfoAccounts,
|
showNodeInfoAccounts,
|
||||||
|
@ -823,8 +829,10 @@ def createServerGroup(path: str, domain: str, port: int,
|
||||||
city = 'London, England'
|
city = 'London, England'
|
||||||
logLoginFailures = False
|
logLoginFailures = False
|
||||||
userAgentsBlocked = []
|
userAgentsBlocked = []
|
||||||
|
maxLikeCount = 10
|
||||||
print('Server running: Group')
|
print('Server running: Group')
|
||||||
runDaemon(sharedItemsFederatedDomains,
|
runDaemon(maxLikeCount,
|
||||||
|
sharedItemsFederatedDomains,
|
||||||
userAgentsBlocked,
|
userAgentsBlocked,
|
||||||
logLoginFailures, city,
|
logLoginFailures, city,
|
||||||
showNodeInfoAccounts,
|
showNodeInfoAccounts,
|
||||||
|
|
|
@ -33,7 +33,8 @@ def htmlConfirmDelete(cssCache: {},
|
||||||
showPublishedDateOnly: bool,
|
showPublishedDateOnly: bool,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
themeName: str, systemLanguage: str) -> str:
|
themeName: str, systemLanguage: str,
|
||||||
|
maxLikeCount: int) -> str:
|
||||||
"""Shows a screen asking to confirm the deletion of a post
|
"""Shows a screen asking to confirm the deletion of a post
|
||||||
"""
|
"""
|
||||||
if '/statuses/' not in messageId:
|
if '/statuses/' not in messageId:
|
||||||
|
@ -74,7 +75,7 @@ def htmlConfirmDelete(cssCache: {},
|
||||||
YTReplacementDomain,
|
YTReplacementDomain,
|
||||||
showPublishedDateOnly,
|
showPublishedDateOnly,
|
||||||
peertubeInstances, allowLocalNetworkAccess,
|
peertubeInstances, allowLocalNetworkAccess,
|
||||||
themeName, systemLanguage,
|
themeName, systemLanguage, maxLikeCount,
|
||||||
False, False, False, False, False)
|
False, False, False, False, False)
|
||||||
deletePostStr += '<center>'
|
deletePostStr += '<center>'
|
||||||
deletePostStr += \
|
deletePostStr += \
|
||||||
|
|
|
@ -32,7 +32,8 @@ def _htmlFrontScreenPosts(recentPostsCache: {}, maxRecentPosts: int,
|
||||||
showPublishedDateOnly: bool,
|
showPublishedDateOnly: bool,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
themeName: str, systemLanguage: str) -> str:
|
themeName: str, systemLanguage: str,
|
||||||
|
maxLikeCount: int) -> str:
|
||||||
"""Shows posts on the front screen of a news instance
|
"""Shows posts on the front screen of a news instance
|
||||||
These should only be public blog posts from the features timeline
|
These should only be public blog posts from the features timeline
|
||||||
which is the blog timeline of the news actor
|
which is the blog timeline of the news actor
|
||||||
|
@ -74,6 +75,7 @@ def _htmlFrontScreenPosts(recentPostsCache: {}, maxRecentPosts: int,
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
themeName, systemLanguage,
|
themeName, systemLanguage,
|
||||||
|
maxLikeCount,
|
||||||
False, False, False, True, False)
|
False, False, False, True, False)
|
||||||
if postStr:
|
if postStr:
|
||||||
profileStr += postStr + separatorStr
|
profileStr += postStr + separatorStr
|
||||||
|
@ -98,7 +100,7 @@ def htmlFrontScreen(rssIconAtTop: bool,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
accessKeys: {},
|
accessKeys: {},
|
||||||
systemLanguage: str,
|
systemLanguage: str, maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: [],
|
sharedItemsFederatedDomains: [],
|
||||||
extraJson: {} = None,
|
extraJson: {} = None,
|
||||||
pageNumber: int = None,
|
pageNumber: int = None,
|
||||||
|
@ -170,7 +172,8 @@ def htmlFrontScreen(rssIconAtTop: bool,
|
||||||
showPublishedDateOnly,
|
showPublishedDateOnly,
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
theme, systemLanguage) + licenseStr
|
theme, systemLanguage,
|
||||||
|
maxLikeCount) + licenseStr
|
||||||
|
|
||||||
# Footer which is only used for system accounts
|
# Footer which is only used for system accounts
|
||||||
profileFooterStr = ' </td>\n'
|
profileFooterStr = ' </td>\n'
|
||||||
|
|
|
@ -48,6 +48,7 @@ def htmlModeration(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the moderation feed as html
|
"""Show the moderation feed as html
|
||||||
This is what you see when selecting the "mod" timeline
|
This is what you see when selecting the "mod" timeline
|
||||||
|
@ -65,7 +66,7 @@ def htmlModeration(cssCache: {}, defaultTimeline: str,
|
||||||
authorized, moderationActionStr, theme,
|
authorized, moderationActionStr, theme,
|
||||||
peertubeInstances, allowLocalNetworkAccess,
|
peertubeInstances, allowLocalNetworkAccess,
|
||||||
textModeBanner, accessKeys, systemLanguage,
|
textModeBanner, accessKeys, systemLanguage,
|
||||||
sharedItemsFederatedDomains)
|
maxLikeCount, sharedItemsFederatedDomains)
|
||||||
|
|
||||||
|
|
||||||
def htmlAccountInfo(cssCache: {}, translate: {},
|
def htmlAccountInfo(cssCache: {}, translate: {},
|
||||||
|
|
|
@ -460,7 +460,8 @@ def _getLikeIconHtml(nickname: str, domainFull: str,
|
||||||
postStartTime,
|
postStartTime,
|
||||||
translate: {}, pageNumberParam: str,
|
translate: {}, pageNumberParam: str,
|
||||||
timelinePostBookmark: str,
|
timelinePostBookmark: str,
|
||||||
boxName: str) -> str:
|
boxName: str,
|
||||||
|
maxLikeCount: int) -> str:
|
||||||
"""Returns html for like icon/button
|
"""Returns html for like icon/button
|
||||||
"""
|
"""
|
||||||
likeStr = ''
|
likeStr = ''
|
||||||
|
@ -475,10 +476,10 @@ def _getLikeIconHtml(nickname: str, domainFull: str,
|
||||||
|
|
||||||
likeCountStr = ''
|
likeCountStr = ''
|
||||||
if likeCount > 0:
|
if likeCount > 0:
|
||||||
if likeCount <= 10:
|
if likeCount <= maxLikeCount:
|
||||||
likeCountStr = ' (' + str(likeCount) + ')'
|
likeCountStr = ' (' + str(likeCount) + ')'
|
||||||
else:
|
else:
|
||||||
likeCountStr = ' (10+)'
|
likeCountStr = ' (' + str(maxLikeCount) + '+)'
|
||||||
if likedByPerson(postJsonObject, nickname, domainFull):
|
if likedByPerson(postJsonObject, nickname, domainFull):
|
||||||
if likeCount == 1:
|
if likeCount == 1:
|
||||||
# liked by the reader only
|
# liked by the reader only
|
||||||
|
@ -1101,6 +1102,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
themeName: str, systemLanguage: str,
|
themeName: str, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
showRepeats: bool = True,
|
showRepeats: bool = True,
|
||||||
showIcons: bool = False,
|
showIcons: bool = False,
|
||||||
manuallyApprovesFollowers: bool = False,
|
manuallyApprovesFollowers: bool = False,
|
||||||
|
@ -1392,7 +1394,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
postStartTime,
|
postStartTime,
|
||||||
translate, pageNumberParam,
|
translate, pageNumberParam,
|
||||||
timelinePostBookmark,
|
timelinePostBookmark,
|
||||||
boxName)
|
boxName, maxLikeCount)
|
||||||
|
|
||||||
_logPostTiming(enableTimingLog, postStartTime, '12.5')
|
_logPostTiming(enableTimingLog, postStartTime, '12.5')
|
||||||
|
|
||||||
|
@ -1673,7 +1675,8 @@ def htmlIndividualPost(cssCache: {},
|
||||||
showPublishedDateOnly: bool,
|
showPublishedDateOnly: bool,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
themeName: str, systemLanguage: str) -> str:
|
themeName: str, systemLanguage: str,
|
||||||
|
maxLikeCount: int) -> str:
|
||||||
"""Show an individual post as html
|
"""Show an individual post as html
|
||||||
"""
|
"""
|
||||||
postStr = ''
|
postStr = ''
|
||||||
|
@ -1715,7 +1718,7 @@ def htmlIndividualPost(cssCache: {},
|
||||||
showPublishedDateOnly,
|
showPublishedDateOnly,
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess, themeName,
|
allowLocalNetworkAccess, themeName,
|
||||||
systemLanguage,
|
systemLanguage, maxLikeCount,
|
||||||
False, authorized, False, False, False)
|
False, authorized, False, False, False)
|
||||||
messageId = removeIdEnding(postJsonObject['id'])
|
messageId = removeIdEnding(postJsonObject['id'])
|
||||||
|
|
||||||
|
@ -1744,6 +1747,7 @@ def htmlIndividualPost(cssCache: {},
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
themeName, systemLanguage,
|
themeName, systemLanguage,
|
||||||
|
maxLikeCount,
|
||||||
False, authorized,
|
False, authorized,
|
||||||
False, False, False) + postStr
|
False, False, False) + postStr
|
||||||
|
|
||||||
|
@ -1775,6 +1779,7 @@ def htmlIndividualPost(cssCache: {},
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
themeName, systemLanguage,
|
themeName, systemLanguage,
|
||||||
|
maxLikeCount,
|
||||||
False, authorized,
|
False, authorized,
|
||||||
False, False, False)
|
False, False, False)
|
||||||
cssFilename = baseDir + '/epicyon-profile.css'
|
cssFilename = baseDir + '/epicyon-profile.css'
|
||||||
|
@ -1797,7 +1802,8 @@ def htmlPostReplies(cssCache: {},
|
||||||
showPublishedDateOnly: bool,
|
showPublishedDateOnly: bool,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
themeName: str, systemLanguage: str) -> str:
|
themeName: str, systemLanguage: str,
|
||||||
|
maxLikeCount: int) -> str:
|
||||||
"""Show the replies to an individual post as html
|
"""Show the replies to an individual post as html
|
||||||
"""
|
"""
|
||||||
repliesStr = ''
|
repliesStr = ''
|
||||||
|
@ -1817,6 +1823,7 @@ def htmlPostReplies(cssCache: {},
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
themeName, systemLanguage,
|
themeName, systemLanguage,
|
||||||
|
maxLikeCount,
|
||||||
False, False, False, False, False)
|
False, False, False, False, False)
|
||||||
|
|
||||||
cssFilename = baseDir + '/epicyon-profile.css'
|
cssFilename = baseDir + '/epicyon-profile.css'
|
||||||
|
|
|
@ -80,7 +80,8 @@ def htmlProfileAfterSearch(cssCache: {},
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
themeName: str,
|
themeName: str,
|
||||||
accessKeys: {},
|
accessKeys: {},
|
||||||
systemLanguage: str) -> str:
|
systemLanguage: str,
|
||||||
|
maxLikeCount: int) -> str:
|
||||||
"""Show a profile page after a search for a fediverse address
|
"""Show a profile page after a search for a fediverse address
|
||||||
"""
|
"""
|
||||||
http = False
|
http = False
|
||||||
|
@ -272,7 +273,7 @@ def htmlProfileAfterSearch(cssCache: {},
|
||||||
showPublishedDateOnly,
|
showPublishedDateOnly,
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
themeName, systemLanguage,
|
themeName, systemLanguage, maxLikeCount,
|
||||||
False, False, False, False, False)
|
False, False, False, False, False)
|
||||||
i += 1
|
i += 1
|
||||||
if i >= 20:
|
if i >= 20:
|
||||||
|
@ -475,7 +476,7 @@ def htmlProfile(rssIconAtTop: bool,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
debug: bool, accessKeys: {}, city: str,
|
debug: bool, accessKeys: {}, city: str,
|
||||||
systemLanguage: str,
|
systemLanguage: str, maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: [],
|
sharedItemsFederatedDomains: [],
|
||||||
extraJson: {} = None, pageNumber: int = None,
|
extraJson: {} = None, pageNumber: int = None,
|
||||||
maxItemsPerPage: int = None) -> str:
|
maxItemsPerPage: int = None) -> str:
|
||||||
|
@ -497,7 +498,7 @@ def htmlProfile(rssIconAtTop: bool,
|
||||||
showPublishedDateOnly,
|
showPublishedDateOnly,
|
||||||
newswire, theme, extraJson,
|
newswire, theme, extraJson,
|
||||||
allowLocalNetworkAccess, accessKeys,
|
allowLocalNetworkAccess, accessKeys,
|
||||||
systemLanguage,
|
systemLanguage, maxLikeCount,
|
||||||
sharedItemsFederatedDomains,
|
sharedItemsFederatedDomains,
|
||||||
pageNumber, maxItemsPerPage)
|
pageNumber, maxItemsPerPage)
|
||||||
|
|
||||||
|
@ -828,7 +829,8 @@ def htmlProfile(rssIconAtTop: bool,
|
||||||
showPublishedDateOnly,
|
showPublishedDateOnly,
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
theme, systemLanguage) + licenseStr
|
theme, systemLanguage,
|
||||||
|
maxLikeCount) + licenseStr
|
||||||
elif selected == 'following':
|
elif selected == 'following':
|
||||||
profileStr += \
|
profileStr += \
|
||||||
_htmlProfileFollowing(translate, baseDir, httpPrefix,
|
_htmlProfileFollowing(translate, baseDir, httpPrefix,
|
||||||
|
@ -882,7 +884,8 @@ def _htmlProfilePosts(recentPostsCache: {}, maxRecentPosts: int,
|
||||||
showPublishedDateOnly: bool,
|
showPublishedDateOnly: bool,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
themeName: str, systemLanguage: str) -> str:
|
themeName: str, systemLanguage: str,
|
||||||
|
maxLikeCount: int) -> str:
|
||||||
"""Shows posts on the profile screen
|
"""Shows posts on the profile screen
|
||||||
These should only be public posts
|
These should only be public posts
|
||||||
"""
|
"""
|
||||||
|
@ -923,6 +926,7 @@ def _htmlProfilePosts(recentPostsCache: {}, maxRecentPosts: int,
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
themeName, systemLanguage,
|
themeName, systemLanguage,
|
||||||
|
maxLikeCount,
|
||||||
False, False, False, True, False)
|
False, False, False, True, False)
|
||||||
if postStr:
|
if postStr:
|
||||||
profileStr += postStr + separatorStr
|
profileStr += postStr + separatorStr
|
||||||
|
|
|
@ -567,7 +567,8 @@ def htmlHistorySearch(cssCache: {}, translate: {}, baseDir: str,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
themeName: str, boxName: str,
|
themeName: str, boxName: str,
|
||||||
systemLanguage: str) -> str:
|
systemLanguage: str,
|
||||||
|
maxLikeCount: int) -> str:
|
||||||
"""Show a page containing search results for your post history
|
"""Show a page containing search results for your post history
|
||||||
"""
|
"""
|
||||||
if historysearch.startswith("'"):
|
if historysearch.startswith("'"):
|
||||||
|
@ -647,7 +648,7 @@ def htmlHistorySearch(cssCache: {}, translate: {}, baseDir: str,
|
||||||
showPublishedDateOnly,
|
showPublishedDateOnly,
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
themeName, systemLanguage,
|
themeName, systemLanguage, maxLikeCount,
|
||||||
showIndividualPostIcons,
|
showIndividualPostIcons,
|
||||||
showIndividualPostIcons,
|
showIndividualPostIcons,
|
||||||
False, False, False)
|
False, False, False)
|
||||||
|
@ -671,7 +672,8 @@ def htmlHashtagSearch(cssCache: {},
|
||||||
showPublishedDateOnly: bool,
|
showPublishedDateOnly: bool,
|
||||||
peertubeInstances: [],
|
peertubeInstances: [],
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
themeName: str, systemLanguage: str) -> str:
|
themeName: str, systemLanguage: str,
|
||||||
|
maxLikeCount: int) -> str:
|
||||||
"""Show a page containing search results for a hashtag
|
"""Show a page containing search results for a hashtag
|
||||||
or after selecting a hashtag from the swarm
|
or after selecting a hashtag from the swarm
|
||||||
"""
|
"""
|
||||||
|
@ -822,7 +824,7 @@ def htmlHashtagSearch(cssCache: {},
|
||||||
showPublishedDateOnly,
|
showPublishedDateOnly,
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
themeName, systemLanguage,
|
themeName, systemLanguage, maxLikeCount,
|
||||||
showRepeats, showIcons,
|
showRepeats, showIcons,
|
||||||
manuallyApprovesFollowers,
|
manuallyApprovesFollowers,
|
||||||
showPublicOnly,
|
showPublicOnly,
|
||||||
|
|
|
@ -400,6 +400,7 @@ def htmlTimeline(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the timeline as html
|
"""Show the timeline as html
|
||||||
"""
|
"""
|
||||||
|
@ -804,6 +805,7 @@ def htmlTimeline(cssCache: {}, defaultTimeline: str,
|
||||||
peertubeInstances,
|
peertubeInstances,
|
||||||
allowLocalNetworkAccess,
|
allowLocalNetworkAccess,
|
||||||
theme, systemLanguage,
|
theme, systemLanguage,
|
||||||
|
maxLikeCount,
|
||||||
boxName != 'dm',
|
boxName != 'dm',
|
||||||
showIndividualPostIcons,
|
showIndividualPostIcons,
|
||||||
manuallyApproveFollowers,
|
manuallyApproveFollowers,
|
||||||
|
@ -998,6 +1000,7 @@ def htmlShares(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the shares timeline as html
|
"""Show the shares timeline as html
|
||||||
"""
|
"""
|
||||||
|
@ -1020,7 +1023,7 @@ def htmlShares(cssCache: {}, defaultTimeline: str,
|
||||||
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
||||||
authorized, None, theme, peertubeInstances,
|
authorized, None, theme, peertubeInstances,
|
||||||
allowLocalNetworkAccess, textModeBanner,
|
allowLocalNetworkAccess, textModeBanner,
|
||||||
accessKeys, systemLanguage,
|
accessKeys, systemLanguage, maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
|
|
||||||
|
|
||||||
|
@ -1045,6 +1048,7 @@ def htmlInbox(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the inbox as html
|
"""Show the inbox as html
|
||||||
"""
|
"""
|
||||||
|
@ -1067,7 +1071,7 @@ def htmlInbox(cssCache: {}, defaultTimeline: str,
|
||||||
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
||||||
authorized, None, theme, peertubeInstances,
|
authorized, None, theme, peertubeInstances,
|
||||||
allowLocalNetworkAccess, textModeBanner,
|
allowLocalNetworkAccess, textModeBanner,
|
||||||
accessKeys, systemLanguage,
|
accessKeys, systemLanguage, maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
|
|
||||||
|
|
||||||
|
@ -1092,6 +1096,7 @@ def htmlBookmarks(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the bookmarks as html
|
"""Show the bookmarks as html
|
||||||
"""
|
"""
|
||||||
|
@ -1114,7 +1119,7 @@ def htmlBookmarks(cssCache: {}, defaultTimeline: str,
|
||||||
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
||||||
authorized, None, theme, peertubeInstances,
|
authorized, None, theme, peertubeInstances,
|
||||||
allowLocalNetworkAccess, textModeBanner,
|
allowLocalNetworkAccess, textModeBanner,
|
||||||
accessKeys, systemLanguage,
|
accessKeys, systemLanguage, maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
|
|
||||||
|
|
||||||
|
@ -1139,6 +1144,7 @@ def htmlInboxDMs(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the DM timeline as html
|
"""Show the DM timeline as html
|
||||||
"""
|
"""
|
||||||
|
@ -1156,7 +1162,7 @@ def htmlInboxDMs(cssCache: {}, defaultTimeline: str,
|
||||||
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
||||||
authorized, None, theme, peertubeInstances,
|
authorized, None, theme, peertubeInstances,
|
||||||
allowLocalNetworkAccess, textModeBanner,
|
allowLocalNetworkAccess, textModeBanner,
|
||||||
accessKeys, systemLanguage,
|
accessKeys, systemLanguage, maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
|
|
||||||
|
|
||||||
|
@ -1181,6 +1187,7 @@ def htmlInboxReplies(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the replies timeline as html
|
"""Show the replies timeline as html
|
||||||
"""
|
"""
|
||||||
|
@ -1199,7 +1206,7 @@ def htmlInboxReplies(cssCache: {}, defaultTimeline: str,
|
||||||
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
||||||
authorized, None, theme, peertubeInstances,
|
authorized, None, theme, peertubeInstances,
|
||||||
allowLocalNetworkAccess, textModeBanner,
|
allowLocalNetworkAccess, textModeBanner,
|
||||||
accessKeys, systemLanguage,
|
accessKeys, systemLanguage, maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
|
|
||||||
|
|
||||||
|
@ -1224,6 +1231,7 @@ def htmlInboxMedia(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the media timeline as html
|
"""Show the media timeline as html
|
||||||
"""
|
"""
|
||||||
|
@ -1242,7 +1250,7 @@ def htmlInboxMedia(cssCache: {}, defaultTimeline: str,
|
||||||
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
||||||
authorized, None, theme, peertubeInstances,
|
authorized, None, theme, peertubeInstances,
|
||||||
allowLocalNetworkAccess, textModeBanner,
|
allowLocalNetworkAccess, textModeBanner,
|
||||||
accessKeys, systemLanguage,
|
accessKeys, systemLanguage, maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
|
|
||||||
|
|
||||||
|
@ -1267,6 +1275,7 @@ def htmlInboxBlogs(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the blogs timeline as html
|
"""Show the blogs timeline as html
|
||||||
"""
|
"""
|
||||||
|
@ -1285,7 +1294,7 @@ def htmlInboxBlogs(cssCache: {}, defaultTimeline: str,
|
||||||
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
||||||
authorized, None, theme, peertubeInstances,
|
authorized, None, theme, peertubeInstances,
|
||||||
allowLocalNetworkAccess, textModeBanner,
|
allowLocalNetworkAccess, textModeBanner,
|
||||||
accessKeys, systemLanguage,
|
accessKeys, systemLanguage, maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
|
|
||||||
|
|
||||||
|
@ -1311,6 +1320,7 @@ def htmlInboxFeatures(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the features timeline as html
|
"""Show the features timeline as html
|
||||||
"""
|
"""
|
||||||
|
@ -1329,7 +1339,7 @@ def htmlInboxFeatures(cssCache: {}, defaultTimeline: str,
|
||||||
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
||||||
authorized, None, theme, peertubeInstances,
|
authorized, None, theme, peertubeInstances,
|
||||||
allowLocalNetworkAccess, textModeBanner,
|
allowLocalNetworkAccess, textModeBanner,
|
||||||
accessKeys, systemLanguage,
|
accessKeys, systemLanguage, maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
|
|
||||||
|
|
||||||
|
@ -1354,6 +1364,7 @@ def htmlInboxNews(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the news timeline as html
|
"""Show the news timeline as html
|
||||||
"""
|
"""
|
||||||
|
@ -1372,7 +1383,7 @@ def htmlInboxNews(cssCache: {}, defaultTimeline: str,
|
||||||
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
||||||
authorized, None, theme, peertubeInstances,
|
authorized, None, theme, peertubeInstances,
|
||||||
allowLocalNetworkAccess, textModeBanner,
|
allowLocalNetworkAccess, textModeBanner,
|
||||||
accessKeys, systemLanguage,
|
accessKeys, systemLanguage, maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
|
|
||||||
|
|
||||||
|
@ -1397,6 +1408,7 @@ def htmlOutbox(cssCache: {}, defaultTimeline: str,
|
||||||
allowLocalNetworkAccess: bool,
|
allowLocalNetworkAccess: bool,
|
||||||
textModeBanner: str,
|
textModeBanner: str,
|
||||||
accessKeys: {}, systemLanguage: str,
|
accessKeys: {}, systemLanguage: str,
|
||||||
|
maxLikeCount: int,
|
||||||
sharedItemsFederatedDomains: []) -> str:
|
sharedItemsFederatedDomains: []) -> str:
|
||||||
"""Show the Outbox as html
|
"""Show the Outbox as html
|
||||||
"""
|
"""
|
||||||
|
@ -1416,5 +1428,5 @@ def htmlOutbox(cssCache: {}, defaultTimeline: str,
|
||||||
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
iconsAsButtons, rssIconAtTop, publishButtonAtTop,
|
||||||
authorized, None, theme, peertubeInstances,
|
authorized, None, theme, peertubeInstances,
|
||||||
allowLocalNetworkAccess, textModeBanner,
|
allowLocalNetworkAccess, textModeBanner,
|
||||||
accessKeys, systemLanguage,
|
accessKeys, systemLanguage, maxLikeCount,
|
||||||
sharedItemsFederatedDomains)
|
sharedItemsFederatedDomains)
|
||||||
|
|
Loading…
Reference in New Issue