forked from indymedia/epicyon
Set minimum number of index pages to load
parent
be91c3b79c
commit
9ae3f23383
5
posts.py
5
posts.py
|
@ -2037,7 +2037,10 @@ def createBoxBase(session,baseDir: str,boxname: str, \
|
||||||
postsCtr=0
|
postsCtr=0
|
||||||
maxPostCtr=None
|
maxPostCtr=None
|
||||||
if pageNumber:
|
if pageNumber:
|
||||||
maxPostCtr=(itemsPerPage+3)*pageNumber
|
minPageNumber=pageNumber
|
||||||
|
if minPageNumber<3:
|
||||||
|
minPageNumber=3
|
||||||
|
maxPostCtr=itemsPerPage*minPageNumber
|
||||||
with open(indexFilename, 'r') as indexFile:
|
with open(indexFilename, 'r') as indexFile:
|
||||||
for postFilename in indexFile:
|
for postFilename in indexFile:
|
||||||
postsInBox[postsCtr]=os.path.join(boxDir, postFilename.replace('\n',''))
|
postsInBox[postsCtr]=os.path.join(boxDir, postFilename.replace('\n',''))
|
||||||
|
|
Loading…
Reference in New Issue